This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[C++ Patch] PR 58596


Hi,

in this ICE on valid, 4.8/4.9 Regression, the problem is that, for a lambda in an NSDMI context, the early return of lambda_expr_this_capture:

   /* In unevaluated context this isn't an odr-use, so just return the
      nearest 'this'.  */
   if (cp_unevaluated_operand)
     return lookup_name (this_identifier);

fails to find a this_identifier. This is expected, in a NSDMI context, as also clarified from the comment a few lines below. Thus I'm handling the issue the same way, that is by way of scope_chain->x_current_class_ptr.

Tested x86_64-linux.

Thanks!
Paolo.

////////////////////////////

Attachment: CL_58596
Description: Text document

Attachment: patch_58596
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]