https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103653
--- Comment #4 from Jonathan Wakely ---
Yes this changed in C++23 so auto(X) creates an rvalue of the decayed type of
x.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103653
--- Comment #3 from Andrew Pinski ---
>But I think auto(x) should also be well-formed.
it is well formed as a declaration.
auto(x) = 1;
Unless something changed in that part of C++ standard too.
The following does work as expected too:
int
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103653
康桓瑋 changed:
What|Removed |Added
Resolution|INVALID |---
Status|RESOLVED
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103653
康桓瑋 changed:
What|Removed |Added
Resolution|--- |INVALID
Status|UNCONFIRMED