diff options
author | pinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-10-21 16:29:58 +0000 |
---|---|---|
committer | pinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-10-21 16:29:58 +0000 |
commit | 6e03009448406dbe2bf36d8a20a1b5f21d8da2a1 (patch) | |
tree | 9a1e960bf3fcbb05dde5a7d547ebaebe89e75e97 /gcc/c-decl.c | |
parent | a057b06168267962905416ba203821b3b1769b0f (diff) | |
download | gcc-6e03009448406dbe2bf36d8a20a1b5f21d8da2a1.tar.gz |
2004-10-21 Andrew Pinski <pinskia@physics.uc.edu>
PR objc/17923
* tree.c (staticp): A CONST_DECL has static storage if either
TREE_STATIC or DECL_EXTERNAL is set.
* c-decl.c (pushdecl_top_level): Accept CONST_DECLs which can
have null names.
2004-10-21 Andrew Pinski <pinskia@physics.uc.edu>
PR objc/17923
* objc-act.c (objc_build_string_object): Create a CONST_DECL
for the NeXT runtime case.
2004-10-21 Andrew Pinski <pinskia@physics.uc.edu>
PR objc/17923
* objc.dg/const-str-7.m: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@89384 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r-- | gcc/c-decl.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c index 9e9813d7f78..a2443ec6c19 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -2128,12 +2128,11 @@ pushdecl_top_level (tree x) { tree name; bool nested = false; - - gcc_assert (TREE_CODE (x) == VAR_DECL); + gcc_assert (TREE_CODE (x) == VAR_DECL || TREE_CODE (x) == CONST_DECL); name = DECL_NAME (x); - gcc_assert (!I_SYMBOL_BINDING (name)); + gcc_assert (TREE_CODE (x) == CONST_DECL || !I_SYMBOL_BINDING (name)); if (TREE_PUBLIC (x)) { |