https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108566
--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-12 branch has been updated by Jason Merrill <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:f483dc1367294d02581e2d98c5f84be4dd67f26b commit r12-9431-gf483dc1367294d02581e2d98c5f84be4dd67f26b Author: Jason Merrill <ja...@redhat.com> Date: Thu Mar 9 23:33:43 2023 -0500 c++: class NTTP and nested anon union [PR108566] We were failing to come up with the name for the anonymous union. It seems like unfortunate redundancy, but the ABI does say that the name of an anonymous union is its first named member. PR c++/108566 gcc/cp/ChangeLog: * mangle.cc (anon_aggr_naming_decl): New. (write_unqualified_name): Use it. gcc/testsuite/ChangeLog: * g++.dg/abi/anon6.C: New test.