diff options
author | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-08-18 15:22:46 +0000 |
---|---|---|
committer | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-08-18 15:22:46 +0000 |
commit | 7ecfd590a05ce0c39ffdeed7bddb1ec755706947 (patch) | |
tree | c1f99fa18011cb80b0ba29f6f480ccdc113baf38 /gcc/cgraphunit.c | |
parent | c4243fe71f63e72e3353ee2ae3f5a8c3c660686d (diff) | |
download | gcc-7ecfd590a05ce0c39ffdeed7bddb1ec755706947.tar.gz |
PR c++/22034
* cgraphunit.c (cgraph_varpool_assemble_pending_decls): Emit debug
info only for local statics, not for member variables.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@103251 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cgraphunit.c')
-rw-r--r-- | gcc/cgraphunit.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c index a10859dd0bc..012cb7c2308 100644 --- a/gcc/cgraphunit.c +++ b/gcc/cgraphunit.c @@ -814,7 +814,10 @@ cgraph_varpool_assemble_pending_decls (void) assemble_variable (decl, 0, 1, 0); /* Local static variables are never seen by check_global_declarations so we need to output debug info by hand. */ - if (decl_function_context (decl) && errorcount == 0 && sorrycount == 0) + if (DECL_CONTEXT (decl) + && (TREE_CODE (DECL_CONTEXT (decl)) == BLOCK + || TREE_CODE (DECL_CONTEXT (decl)) == FUNCTION_DECL) + && errorcount == 0 && sorrycount == 0) { timevar_push (TV_SYMOUT); (*debug_hooks->global_decl) (decl); |