This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: False ODR violation positives on anonymous namespace types


On 05/11/2015 04:39 PM, Jan Hubicka wrote:
What happens in LTO is that lto-symtab decide to merge the two declarations of
foo.  At this time it has chance to output the warning.  For that it needs to
be able to work out that these declarations are having different types, but
because LTO merge canonical types on structural basis, types_compatible_p
(long, int) will return true.

OK. So I guess it makes sense to check built-in integer types as well, but compound types should be compared structurally.

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]