From: Jason Merrill Date: Fri, 10 Oct 2014 20:24:36 +0000 (-0400) Subject: * semantics.c (finish_id_expression): Check for error_mark_node. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cfb71cadfd586194ba65150a1d535b8ad4229d22;p=gcc.git * semantics.c (finish_id_expression): Check for error_mark_node. From-SVN: r216104 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 7b2d09f1402..1414f2be2f9 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2014-10-10 Jason Merrill + + * semantics.c (finish_id_expression): Check for error_mark_node. + 2014-10-09 Jason Merrill PR c++/63207 diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index ab8c82ae5f6..08658a7f305 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -3272,7 +3272,11 @@ finish_id_expression (tree id_expression, /* Disallow uses of local variables from containing functions, except within lambda-expressions. */ if (outer_automatic_var_p (decl)) - decl = process_outer_var_ref (decl, tf_warning_or_error); + { + decl = process_outer_var_ref (decl, tf_warning_or_error); + if (decl == error_mark_node) + return error_mark_node; + } /* Also disallow uses of function parameters outside the function body, except inside an unevaluated context (i.e. decltype). */