[Bug c++/89422] [8 Regression] ICE in field_byte_offset, at dwarf2out.c:19086
jason at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Feb 21 23:08:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89422
--- Comment #4 from Jason Merrill <jason at gcc dot gnu.org> ---
Author: jason
Date: Thu Feb 21 23:07:47 2019
New Revision: 269081
URL: https://gcc.gnu.org/viewcvs?rev=269081&root=gcc&view=rev
Log:
PR c++/89422 - ICE with -g and lambda in default arg in template.
Here, we were trying to instantiate the default argument before setting
DECL_FRIEND_CONTEXT, so that the instantiated lambda ended up being treated
as part of the S template, which confused dwarf2out.
* pt.c (tsubst_function_decl): SET_DECL_FRIEND_CONTEXT sooner.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-defarg9.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/pt.c
More information about the Gcc-bugs
mailing list