underlying type for enums
Joseph S. Myers
jsm@polyomino.org.uk
Wed Dec 3 10:29:00 GMT 2003
On Wed, 3 Dec 2003, Jamie Lokier wrote:
> struct { E e : 2; unsigned f : 1; } s;
> s.e = (__typeof__(s.e)) e2;
We just disallowed typeof on bit-fields (by analogy with sizeof, and if
you allowed just types to escape from structures in this way you'd then
need to deal with declarations of outside objects of such types; using
such types to declare new bit-fields in new structures;
sizeof(typeof(s.e)); ...).
--
Joseph S. Myers
jsm@polyomino.org.uk
More information about the Gcc
mailing list