------- Comment #6 from pinskia at gcc dot gnu dot org 2006-04-08 23:11 ------- Here is the patch which fixes this issue for me: Index: cp-objcp-common.c =================================================================== --- cp-objcp-common.c (revision 112789) +++ cp-objcp-common.c (working copy) @@ -179,7 +179,7 @@ cxx_types_compatible_p (tree x, tree y) if (POINTER_TYPE_P (x) && POINTER_TYPE_P (y) && TYPE_MODE (x) == TYPE_MODE (y) && TYPE_REF_CAN_ALIAS_ALL (x) == TYPE_REF_CAN_ALIAS_ALL (y) - && same_type_p (TREE_TYPE (x), TREE_TYPE (y))) + && same_type_ignoring_top_level_qualifiers_p (TREE_TYPE (x), TREE_TYPE (y))) return 1;
return 0; -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Component|tree-optimization |c++ http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27084