diff options
Diffstat (limited to 'gcc/cp/cp-lang.c')
-rw-r--r-- | gcc/cp/cp-lang.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/gcc/cp/cp-lang.c b/gcc/cp/cp-lang.c index 0e44a08..da5d6fb 100644 --- a/gcc/cp/cp-lang.c +++ b/gcc/cp/cp-lang.c @@ -39,16 +39,12 @@ enum c_language_kind c_language = clk_cxx; /* Lang hooks common to C++ and ObjC++ are declared in cp/cp-objcp-common.h; consequently, there should be very few hooks below. */ -static int cxx_types_compatible_p (tree, tree); - #undef LANG_HOOKS_NAME #define LANG_HOOKS_NAME "GNU C++" #undef LANG_HOOKS_INIT #define LANG_HOOKS_INIT cxx_init #undef LANG_HOOKS_DECL_PRINTABLE_NAME #define LANG_HOOKS_DECL_PRINTABLE_NAME cxx_printable_name -#undef LANG_HOOKS_TYPES_COMPATIBLE_P -#define LANG_HOOKS_TYPES_COMPATIBLE_P cxx_types_compatible_p #undef LANG_HOOKS_FOLD_OBJ_TYPE_REF #define LANG_HOOKS_FOLD_OBJ_TYPE_REF cp_fold_obj_type_ref @@ -99,25 +95,6 @@ const char *const tree_code_name[] = { /* Lang hook routines common to C++ and ObjC++ appear in cp/cp-objcp-common.c; there should be very few routines below. */ -/* This compares two types for equivalence ("compatible" in C-based languages). - This routine should only return 1 if it is sure. It should not be used - in contexts where erroneously returning 0 causes problems. */ - -static int cxx_types_compatible_p (tree x, tree y) -{ - if (same_type_ignoring_top_level_qualifiers_p (x, y)) - return 1; - - /* Once we get to the middle-end, references and pointers are - interchangeable. FIXME should we try to replace all references with - pointers? */ - if (POINTER_TYPE_P (x) && POINTER_TYPE_P (y) - && same_type_p (TREE_TYPE (x), TREE_TYPE (y))) - return 1; - - return 0; -} - /* The following function does something real, but only in Objective-C++. */ tree |