I'm trying to figure out how initialization of anonymous
structures and unions is supposed to work, particularly when
using brace-enclosed initializer lists without designators.
[..elaboration..]
In general, GCC and Clang seem to be acting like an anonymous
structure or union participates in initialization as a structure
or union, even though it is unnamed. This would be a reasonable
thing to do in the abstract, but I don't see how it agrees with
the wording in the standard. Am I missing something, or do GCC
and Clang get this wrong?
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 248 |
Nodes: | 16 (2 / 14) |
Uptime: | 41:25:53 |
Calls: | 5,495 |
Calls today: | 3 |
Files: | 11,665 |
Messages: | 5,038,649 |
Posted today: | 2 |