[Bug c++/96645] [13/14/15/16/17 Regression] [CWG2335] std::variant default constructor and unparsed DMI
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sun Jul 26 14:51:16 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96645
--- Comment #39 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Jason Merrill <jason@gcc.gnu.org>:
https://gcc.gnu.org/g:e3e1c72649c3a0b48af70f88bcd942c46b0d00ab
commit r17-2718-ge3e1c72649c3a0b48af70f88bcd942c46b0d00ab
Author: Jason Merrill <jason@redhat.com>
Date: Fri Jul 24 15:17:32 2026 -0400
c++: parse trivial DMI immediately [PR96645]
The current direction of CWG2335 is to parse complete-class contexts as
needed rather than always wait until the end of the outermost class.
This doesn't fully implement that (nor fully fix PR96645), but takes a step
in that direction by allowing simple cases that do no name lookup; then
being in complete class scope makes no difference.
CWG 2335
PR c++/96645
gcc/cp/ChangeLog:
* parser.cc (cp_parser_early_parsing_nsdmi): New.
(cp_parser_member_declaration): Call it.
gcc/testsuite/ChangeLog:
* g++.dg/cpp0x/nsdmi10.C: Distinguish simple case.
* g++.dg/ext/is_constructible7.C: New.
More information about the Gcc-bugs
mailing list