On Thu, Jan 24, 2008 at 04:06:47PM +0100, Richard Guenther wrote: > On Jan 24, 2008 3:58 PM, Doug Gregor <[EMAIL PROTECTED]> wrote: > The middle-end type system (useless_type_conversion_p) says that > pointers to int and pointers to int __attribute__((may_alias)) are > distinct (you can't use one in place of the other without changning > semantics) - because the pointed to types have different alias sets. > > Now, for rvalues that doesn't matter, so indeed a value of type > int and a value of type int __attribute__((may_alias)) can be used > in place of each other. So I stand corrected and they should indeed > have the same canonical type.
See also http://gcc.gnu.org/PR34936. Is int __attribute__((may_alias)) supposed to be mangled the same as int? And if so, it should for cp/call.c purposes be treated the same as well. Jakub