https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
--- Comment #8 from Jason Merrill ---
(In reply to Jason Merrill from comment #7)
> It does seem wrong that a constexpr function can't define a constexpr static
> local variable.
Incidentally, this was fixed for C++23 by P2647, implemented in GC
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
--- Comment #7 from Jason Merrill ---
(In reply to Kimon.Hoffmann from comment #6)
> The situation as it stands is unfortunate though, since the standard does
> not allow "static constexpr" variables in constexpr functions. Therefor I
> don't see
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
--- Comment #6 from Kimon.Hoffmann at lawo dot com ---
Thanks for investigating this report and clarifying the underlying issue!
I was afraid that this was a case of UB, but was misled by the cited standard
section that mentioned lifetime extensi
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
Bug 85873 depends on bug 67445, which changed state.
Bug 67445 Summary: New warning: returning std::initializer_list bound to
temporary
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67445
What|Removed |Added
---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
Jason Merrill changed:
What|Removed |Added
Status|ASSIGNED|RESOLVED
Resolution|---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
--- Comment #4 from Jason Merrill ---
Author: jason
Date: Fri Jun 1 22:48:58 2018
New Revision: 261091
URL: https://gcc.gnu.org/viewcvs?rev=261091&root=gcc&view=rev
Log:
PR c++/85873 - constant initializer_list array not in .rodata.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
--- Comment #3 from Jason Merrill ---
Author: jason
Date: Wed May 30 17:33:06 2018
New Revision: 260969
URL: https://gcc.gnu.org/viewcvs?rev=260969&root=gcc&view=rev
Log:
PR c++/85873 - constant initializer_list array not in .rodata.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
Jason Merrill changed:
What|Removed |Added
Keywords|wrong-code |missed-optimization
Depends on|
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85873
Jason Merrill changed:
What|Removed |Added
Status|NEW |ASSIGNED
CC|