re PR c++/70540 (ICE on invalid code in cxx_incomplete_type_diagnostic, at cp/typeck2.c:569)
/cp 2016-04-21 Paolo Carlini <paolo.carlini@oracle.com> PR c++/70540 * semantics.c (process_outer_var_ref): Unconditionally return error_mark_node when mark_used returns false. /testsuite 2016-04-21 Paolo Carlini <paolo.carlini@oracle.com> PR c++/70540 * g++.dg/cpp0x/auto48.C: New. From-SVN: r235348
This commit is contained in:
parent
aedf4e122b
commit
2070009860
@ -1,3 +1,9 @@
|
||||
2016-04-21 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/70540
|
||||
* semantics.c (process_outer_var_ref): Unconditionally return
|
||||
error_mark_node when mark_used returns false.
|
||||
|
||||
2016-04-21 Marek Polacek <polacek@redhat.com>
|
||||
|
||||
PR c++/70513
|
||||
|
@ -3281,7 +3281,7 @@ process_outer_var_ref (tree decl, tsubst_flags_t complain)
|
||||
tree initializer = convert_from_reference (decl);
|
||||
|
||||
/* Mark it as used now even if the use is ill-formed. */
|
||||
if (!mark_used (decl, complain) && !(complain & tf_error))
|
||||
if (!mark_used (decl, complain))
|
||||
return error_mark_node;
|
||||
|
||||
bool saw_generic_lambda = false;
|
||||
|
@ -1,3 +1,8 @@
|
||||
2016-04-21 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/70540
|
||||
* g++.dg/cpp0x/auto48.C: New.
|
||||
|
||||
2016-04-21 Marek Polacek <polacek@redhat.com>
|
||||
|
||||
PR c++/70513
|
||||
|
8
gcc/testsuite/g++.dg/cpp0x/auto48.C
Normal file
8
gcc/testsuite/g++.dg/cpp0x/auto48.C
Normal file
@ -0,0 +1,8 @@
|
||||
// PR c++/70540
|
||||
// { dg-do compile { target c++11 } }
|
||||
|
||||
void
|
||||
foo ()
|
||||
{
|
||||
auto f = [&] { return f; }; // { dg-error "before deduction" }
|
||||
}
|
Loading…
Reference in New Issue
Block a user