summaryrefslogtreecommitdiffstats
path: root/gcc/tree.c
diff options
context:
space:
mode:
authorbryce <bryce@138bc75d-0d04-0410-961f-82ee72b054a4>2002-05-24 09:19:55 +0000
committerbryce <bryce@138bc75d-0d04-0410-961f-82ee72b054a4>2002-05-24 09:19:55 +0000
commite9750a4eb43a8fc219810d4a6745baa42173a430 (patch)
tree3ee22b65c0acd2a88905426630f9cb23de592473 /gcc/tree.c
parentfe44416c8519614f86a66aa1ee0cbbe28c3c8e88 (diff)
downloadppe42-gcc-e9750a4eb43a8fc219810d4a6745baa42173a430.tar.gz
ppe42-gcc-e9750a4eb43a8fc219810d4a6745baa42173a430.zip
* tree.c (decl_type_context): Return NULL_TREE if decl's context is a
namespace. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@53828 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree.c')
-rw-r--r--gcc/tree.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/tree.c b/gcc/tree.c
index 17731c82f23..58ec6f8e5ed 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -4212,6 +4212,9 @@ decl_type_context (decl)
while (context)
{
+ if (TREE_CODE (context) == NAMESPACE_DECL)
+ return NULL_TREE;
+
if (TREE_CODE (context) == RECORD_TYPE
|| TREE_CODE (context) == UNION_TYPE
|| TREE_CODE (context) == QUAL_UNION_TYPE)
OpenPOWER on IntegriCloud