diff options
Diffstat (limited to 'gcc/cp/cp-objcp-common.c')
-rw-r--r-- | gcc/cp/cp-objcp-common.c | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/gcc/cp/cp-objcp-common.c b/gcc/cp/cp-objcp-common.c index e1397b7..84f0b59 100644 --- a/gcc/cp/cp-objcp-common.c +++ b/gcc/cp/cp-objcp-common.c @@ -366,7 +366,8 @@ names_builtin_p (const char *name) tree id = get_identifier (name); if (tree binding = get_global_binding (id)) { - if (TREE_CODE (binding) == FUNCTION_DECL && DECL_IS_BUILTIN (binding)) + if (TREE_CODE (binding) == FUNCTION_DECL + && DECL_IS_UNDECLARED_BUILTIN (binding)) return true; /* Handle the case when an overload for a built-in name exists. */ @@ -376,7 +377,7 @@ names_builtin_p (const char *name) for (ovl_iterator it (binding); it; ++it) { tree decl = *it; - if (DECL_IS_BUILTIN (decl)) + if (DECL_IS_UNDECLARED_BUILTIN (decl)) return true; } } @@ -390,6 +391,7 @@ names_builtin_p (const char *name) case RID_BUILTIN_HAS_ATTRIBUTE: case RID_BUILTIN_SHUFFLE: case RID_BUILTIN_LAUNDER: + case RID_BUILTIN_BIT_CAST: case RID_OFFSETOF: case RID_HAS_NOTHROW_ASSIGN: case RID_HAS_NOTHROW_CONSTRUCTOR: @@ -436,6 +438,9 @@ cp_register_dumps (gcc::dump_manager *dumps) class_dump_id = dumps->dump_register (".class", "lang-class", "lang-class", DK_lang, OPTGROUP_NONE, false); + module_dump_id = dumps->dump_register + (".module", "lang-module", "lang-module", DK_lang, OPTGROUP_NONE, false); + raw_dump_id = dumps->dump_register (".raw", "lang-raw", "lang-raw", DK_lang, OPTGROUP_NONE, false); } @@ -488,6 +493,7 @@ cp_common_init_ts (void) MARK_TS_EXP (ALIGNOF_EXPR); MARK_TS_EXP (ARROW_EXPR); MARK_TS_EXP (AT_ENCODE_EXPR); + MARK_TS_EXP (BIT_CAST_EXPR); MARK_TS_EXP (CAST_EXPR); MARK_TS_EXP (CONST_CAST_EXPR); MARK_TS_EXP (CTOR_INITIALIZER); @@ -548,4 +554,16 @@ cp_common_init_ts (void) c_common_init_ts (); } +/* Handle C++-specficic options here. Punt to c_common otherwise. */ + +bool +cp_handle_option (size_t scode, const char *arg, HOST_WIDE_INT value, + int kind, location_t loc, + const struct cl_option_handlers *handlers) +{ + if (handle_module_option (unsigned (scode), arg, value)) + return true; + return c_common_handle_option (scode, arg, value, kind, loc, handlers); +} + #include "gt-cp-cp-objcp-common.h" |