diff options
author | mrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-05-17 20:11:44 +0000 |
---|---|---|
committer | mrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-05-17 20:11:44 +0000 |
commit | ddb5d39db4331cd049d1e9f35aa7d41a486fb366 (patch) | |
tree | b42ed8b5d16d1706b3b4c8508c64d8b1dab121f5 /gcc/c-decl.c | |
parent | 0ced0389c95a9b5af0ac18148d00d75e35849019 (diff) | |
download | gcc-ddb5d39db4331cd049d1e9f35aa7d41a486fb366.tar.gz |
Yet more Objective-C++...
* c-common.h (objc_finish_try_stmt): Add.
(objc_build_synchronized): Add.
(objc_generate_write_barrier): Add.
* stub-objc.c (objc_build_synchronized): Add return value.
(objc_finish_try_stmt): Likewise.
(objc_generate_write_barrier): Add.
* c-common.h (objc_rewrite_function_call): Add.
* c-typeck.c (build_function_call): Allow objc to rewrite
FUNCTION_DECLs.
(build_modify_expr): Allow objc to generate write barriers.
* c.opt (Wassign-intercept): Add.
(Wstrict-selector-match): Add.
(fobjc-call-cxx-cdtors): Add.
(fobjc-direct-dispatch): Add.
(fobjc-gc): Add.
* dbxout.c (get_lang_number): Add Objective-C++ support.
* doc/invoke.texi (-fobjc-call-cxx-cdtors): Likewise.
(-Wstrict-selector-match): Likewise.
(-fobjc-direct-dispatch): Likewise.
(-Wassign-intercept): Likewise.
(Overall Options): Likewise.
* gengtype.c (get_output_file_with_visibility): Likewise.
* stub-objc.c (objc_rewrite_function_call): Add.
* config/darwin.h (ASM_OUTPUT_LABELREF): Improved quoting support.
* c-common.c (flag_objc_exceptions): Remove.
(flag_objc_sjlj_exceptions): Remove.
* c-decl.c (objc_mark_locals_volatile): Don't change decls
that are already ok.
* c-opts.c (c_common_handle_option, case
OPT_fobjc_exceptions): Remove.
(case OPT_fobjc_sjlj_exceptions): Remove
* c.opt (fobjc-call-cxx-cdtors): Have opt create the flag.
(fobjc-exceptions): Likewise.
(fobjc-sjlj-exceptions): Likewise.
* config/rs6000/darwin.h (OFFS_MSGSEND_FAST): Add.
(OFFS_ASSIGNIVAR_FAST): Add.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@99858 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r-- | gcc/c-decl.c | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c index e189d3629dd..b71838755f8 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -567,12 +567,22 @@ objc_mark_locals_volatile (void *enclosing_blk) { for (b = scope->bindings; b; b = b->prev) { - if (TREE_CODE (b->decl) == VAR_DECL - || TREE_CODE (b->decl) == PARM_DECL) + tree decl = b->decl; + + /* Do not mess with variables that are 'static' or (already) + 'volatile'. */ + if (!TREE_THIS_VOLATILE (decl) && !TREE_STATIC (decl) + && (TREE_CODE (decl) == VAR_DECL + || TREE_CODE (decl) == PARM_DECL)) { - C_DECL_REGISTER (b->decl) = 0; - DECL_REGISTER (b->decl) = 0; - TREE_THIS_VOLATILE (b->decl) = 1; + TREE_TYPE (decl) + = build_qualified_type (TREE_TYPE (decl), + (TYPE_QUALS (TREE_TYPE (decl)) + | TYPE_QUAL_VOLATILE)); + TREE_THIS_VOLATILE (decl) = 1; + TREE_SIDE_EFFECTS (decl) = 1; + DECL_REGISTER (decl) = 0; + C_DECL_REGISTER (decl) = 0; } } |