projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9e18f57
)
(duplicate_decl): If making decl non-external, copy context from old
author
Richard Kenner
<kenner@gcc.gnu.org>
Tue, 5 Mar 1996 12:51:14 +0000
(07:51 -0500)
committer
Richard Kenner
<kenner@gcc.gnu.org>
Tue, 5 Mar 1996 12:51:14 +0000
(07:51 -0500)
to new.
From-SVN: r11439
gcc/c-decl.c
patch
|
blob
|
history
diff --git
a/gcc/c-decl.c
b/gcc/c-decl.c
index 65dfa01270e9824d612ea64e1818add2fe6a63a8..b7379560f74e1066a7984de0443a942254ef53e8 100644
(file)
--- a/
gcc/c-decl.c
+++ b/
gcc/c-decl.c
@@
-1843,6
+1843,8
@@
duplicate_decls (newdecl, olddecl, different_binding_level)
DECL_EXTERNAL (newdecl) = DECL_EXTERNAL (olddecl);
/* An extern decl does not override previous storage class. */
TREE_PUBLIC (newdecl) = TREE_PUBLIC (olddecl);
+ if (! DECL_EXTERNAL (newdecl))
+ DECL_CONTEXT (newdecl) = DECL_CONTEXT (olddecl);
}
else
{