https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61991
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- GCC, clang and ICC all have this same behavior in that if y is not used, the y is not initialized or deconstructed.
pinskia at gcc dot gnu.org via Gcc-bugs Sun, 22 Aug 2021 16:18:29 -0700
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61991
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- GCC, clang and ICC all have this same behavior in that if y is not used, the y is not initialized or deconstructed.