https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108218
Patrick Palka <ppalka at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ppalka at gcc dot gnu.org See Also| |https://gcc.gnu.org/bugzill | |a/show_bug.cgi?id=108219 --- Comment #9 from Patrick Palka <ppalka at gcc dot gnu.org> --- (In reply to Steven Sun from comment #7) > I got one simple idea as a workaround. I do not have the resources to do the > tests. FWIW that seems like the right idea, but it regresses gcc/testsuite/g++.dg/DRs/dr2392.C: $ cat gcc/testsuite/g++.dg/DRs/dr2392.C // DR 2392 // { dg-do compile { target c++11 } } template <class T = void> constexpr int foo () { T t; return 1; } using V = decltype (new int[foo ()]); $ gcc gcc/testsuite/g++.dg/DRs/dr2392.C gcc/testsuite/g++.dg/DRs/dr2392.C: In instantiation of ‘constexpr int foo() [with T = void]’: gcc/testsuite/g++.dg/DRs/dr2392.C:12:33: required from here gcc/testsuite/g++.dg/DRs/dr2392.C:8:5: error: variable or field ‘t’ declared void 8 | T t; | ^