https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102013
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This is interesting:
struct A { int x = 6; };
struct B { int x = 3; };
union U {
A a;
B b;
};
static_assert (U{}.a.x==6);
U a{};
int main() {
if (a.a.x != 6)
__builtin_abort();
}
The static_assert works ....
