https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103668
Jonathan Wakely changed:
What|Removed |Added
Status|UNCONFIRMED |RESOLVED
Resolution|---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103668
--- Comment #4 from Andrei-Edward Popa ---
Yes, I really missed this constexpr instead of const, this is clear for me.
Thank you!
I think this thread can be closed now.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103668
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #3
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103668
--- Comment #2 from Andrei-Edward Popa ---
This code is valid in MSVC compiler, that's why I'm wondering about it.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103668
--- Comment #1 from Jonathan Wakely ---
I don't think this is valid C++.
A vector created in a constexpr function must be destroyed there as well, it
cannot escape from the function.