aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree.h
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2003-08-29 14:57:05 -0700
committerRichard Henderson <rth@gcc.gnu.org>2003-08-29 14:57:05 -0700
commit4b1e44bee1cc164e8b6660eae8980a0e52770f06 (patch)
tree4633005da8f64b1767538dcd1ee8920a7bf39820 /gcc/tree.h
parent05a5fba9c719bedb9584cdec2e677636038be449 (diff)
downloadgcc-4b1e44bee1cc164e8b6660eae8980a0e52770f06.zip
gcc-4b1e44bee1cc164e8b6660eae8980a0e52770f06.tar.gz
gcc-4b1e44bee1cc164e8b6660eae8980a0e52770f06.tar.bz2
c-tree.h (C_DECL_FILE_SCOPE): Move ...
* c-tree.h (C_DECL_FILE_SCOPE): Move ... * tree.h (DECL_FILE_SCOPE_P): ... here, and rename. * c-decl.c, c-objc-common.c, c-typeck.c: Update to match. From-SVN: r70925
Diffstat (limited to 'gcc/tree.h')
-rw-r--r--gcc/tree.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/tree.h b/gcc/tree.h
index c553750..7f99a51 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -1624,6 +1624,11 @@ struct tree_type GTY(())
#define DECL_ESTIMATED_INSNS(NODE) \
(FUNCTION_DECL_CHECK (NODE)->decl.u1.i)
+/* Nonzero for a decl which is at file scope. */
+#define DECL_FILE_SCOPE_P(EXP) \
+ (! DECL_CONTEXT (EXP) \
+ || TREE_CODE (DECL_CONTEXT (EXP)) == TRANSLATION_UNIT_DECL)
+
struct function;
struct tree_decl GTY(())