mirror of git://gcc.gnu.org/git/gcc.git
PR c++/88825 - ICE with bogus function return type deduction.
* typeck.c (can_do_nrvo_p): Check error_mark_node. * g++.dg/cpp1y/auto-fn55.C: New test. From-SVN: r267926
This commit is contained in:
parent
a30d019637
commit
f80aa3999d
|
|
@ -4,6 +4,9 @@
|
||||||
* decl2.c (maybe_emit_vtables): Check CLASSTYPE_LAZY_DESTRUCTOR.
|
* decl2.c (maybe_emit_vtables): Check CLASSTYPE_LAZY_DESTRUCTOR.
|
||||||
Fix formatting.
|
Fix formatting.
|
||||||
|
|
||||||
|
PR c++/88825 - ICE with bogus function return type deduction.
|
||||||
|
* typeck.c (can_do_nrvo_p): Check error_mark_node.
|
||||||
|
|
||||||
2019-01-14 Tom Honermann <tom@honermann.net>
|
2019-01-14 Tom Honermann <tom@honermann.net>
|
||||||
|
|
||||||
Implement P0482R5, char8_t: A type for UTF-8 characters and strings
|
Implement P0482R5, char8_t: A type for UTF-8 characters and strings
|
||||||
|
|
|
||||||
|
|
@ -9343,6 +9343,8 @@ is_std_move_p (tree fn)
|
||||||
static bool
|
static bool
|
||||||
can_do_nrvo_p (tree retval, tree functype)
|
can_do_nrvo_p (tree retval, tree functype)
|
||||||
{
|
{
|
||||||
|
if (functype == error_mark_node)
|
||||||
|
return false;
|
||||||
if (retval)
|
if (retval)
|
||||||
STRIP_ANY_LOCATION_WRAPPER (retval);
|
STRIP_ANY_LOCATION_WRAPPER (retval);
|
||||||
tree result = DECL_RESULT (current_function_decl);
|
tree result = DECL_RESULT (current_function_decl);
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,8 @@
|
||||||
|
2019-01-14 Marek Polacek <polacek@redhat.com>
|
||||||
|
|
||||||
|
PR c++/88825 - ICE with bogus function return type deduction.
|
||||||
|
* g++.dg/cpp1y/auto-fn55.C: New test.
|
||||||
|
|
||||||
2019-01-14 Jakub Jelinek <jakub@redhat.com>
|
2019-01-14 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
* g++.dg/cpp1z/feat-cxx1z.C: Add tests for
|
* g++.dg/cpp1z/feat-cxx1z.C: Add tests for
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
// PR c++/88825
|
||||||
|
// { dg-do compile { target c++14 } }
|
||||||
|
|
||||||
|
auto f () -> auto *
|
||||||
|
{
|
||||||
|
int t = 0;
|
||||||
|
return t; // { dg-error "unable to deduce" }
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue