diff options
author | Geoffrey Keating <geoffk@apple.com> | 2004-08-05 05:52:01 +0000 |
---|---|---|
committer | Geoffrey Keating <geoffk@gcc.gnu.org> | 2004-08-05 05:52:01 +0000 |
commit | 0e6df31e198fd8c0ab0daacc631de05365c2c216 (patch) | |
tree | dd22110790902e6a0fb0065c11210552323ea19e /gcc/expr.c | |
parent | 99b1c586a59f235bb36457739f40ffe98fb18b66 (diff) | |
download | gcc-0e6df31e198fd8c0ab0daacc631de05365c2c216.zip gcc-0e6df31e198fd8c0ab0daacc631de05365c2c216.tar.gz gcc-0e6df31e198fd8c0ab0daacc631de05365c2c216.tar.bz2 |
re PR c/14516 (-fleading-underscore does not work correctly for file static variables)
2004-08-04 Geoffrey Keating <geoffk@apple.com>
PR 14516
* c-common.c (c_expand_decl): Don't special-case static VAR_DECLs.
* c-common.h (make_rtl_for_local_static): Delete.
* c-decl.c (shadow_tag_warned): Clean up comment.
(finish_decl): Clean up spacing. Use set_user_assembler_name when
appropriate. Don't pass asmspec to rest_of_decl_compilation.
* c-semantics.c (make_rtl_for_local_static): Delete.
* expr.c (init_block_move_fn): Use set_user_assembler_name.
(init_block_clear_fn): Likewise.
* passes.c (rest_of_decl_compilation): Remove asmspec parameter,
expect it to be in DECL_ASSEMBLER_NAME. Update callers in many files.
* toplev.h (rest_of_decl_compilation): Remove asmspec parameter.
* tree.h (make_decl_rtl): Remove second parameter.
(set_user_assembler_name): New.
* varasm.c (set_user_assembler_name): New.
(make_decl_rtl): Remove second parameter. Update callers in many
files.
Index: cp/ChangeLog
2004-08-04 Geoffrey Keating <geoffk@apple.com>
* decl.c (make_rtl_for_nonlocal_decl): Set DECL_ASSEMBLER_NAME rather
than passing it as a parameter to rest_of_decl_compilation.
* decl2.c (grokfield): Use set_user_assembler_name.
From-SVN: r85593
Diffstat (limited to 'gcc/expr.c')
-rw-r--r-- | gcc/expr.c | 16 |
1 files changed, 5 insertions, 11 deletions
@@ -1368,10 +1368,7 @@ init_block_move_fn (const char *asmspec) } if (asmspec) - { - SET_DECL_RTL (block_move_fn, NULL_RTX); - SET_DECL_ASSEMBLER_NAME (block_move_fn, get_identifier (asmspec)); - } + set_user_assembler_name (block_move_fn, asmspec); } static tree @@ -1385,7 +1382,7 @@ emit_block_move_libcall_fn (int for_call) if (for_call && !emitted_extern) { emitted_extern = true; - make_decl_rtl (block_move_fn, NULL); + make_decl_rtl (block_move_fn); assemble_external (block_move_fn); } @@ -2432,10 +2429,7 @@ init_block_clear_fn (const char *asmspec) } if (asmspec) - { - SET_DECL_RTL (block_clear_fn, NULL_RTX); - SET_DECL_ASSEMBLER_NAME (block_clear_fn, get_identifier (asmspec)); - } + set_user_assembler_name (block_clear_fn, asmspec); } static tree @@ -2449,7 +2443,7 @@ clear_storage_libcall_fn (int for_call) if (for_call && !emitted_extern) { emitted_extern = true; - make_decl_rtl (block_clear_fn, NULL); + make_decl_rtl (block_clear_fn); assemble_external (block_clear_fn); } @@ -6044,7 +6038,7 @@ expand_var (tree var) else if (TREE_CODE (var) == VAR_DECL && !TREE_STATIC (var)) expand_decl (var); else if (TREE_CODE (var) == VAR_DECL && TREE_STATIC (var)) - rest_of_decl_compilation (var, NULL, 0, 0); + rest_of_decl_compilation (var, 0, 0); else if (TREE_CODE (var) == TYPE_DECL || TREE_CODE (var) == CONST_DECL || TREE_CODE (var) == FUNCTION_DECL |