underlying type for enums

Joseph S. Myers jsm@polyomino.org.uk
Tue Dec 2 10:28:00 GMT 2003


On Tue, 2 Dec 2003, Richard Henderson wrote:

> Indeed, I would say that the PR is valid because 6.2.7/1 specifies
> that the declaration tags must match if present.  But failing that
> it mentions same names and values.

That paragraph is for types in different translation units, and I think
its rules (and the slightly different C90 rules) are properly implemented
in tagged_types_tu_compatible_p.  For enumeration types in the same
translation unit, there seems to be nothing to make two different types
compatible at all.

-- 
Joseph S. Myers
jsm@polyomino.org.uk



More information about the Gcc mailing list