aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree.c
diff options
context:
space:
mode:
authorKai Tietz <kai.tietz@onevision.com>2009-05-29 06:01:02 +0000
committerKai Tietz <ktietz@gcc.gnu.org>2009-05-29 08:01:02 +0200
commit055df276d4e2b36c030223f39cd84743aaac8def (patch)
tree27557fbefd60e25a0fdee561b47c838c6ce9d2b6 /gcc/tree.c
parent4cfaf1ec98904cdf03c4759628d115e90ab03666 (diff)
downloadgcc-055df276d4e2b36c030223f39cd84743aaac8def.zip
gcc-055df276d4e2b36c030223f39cd84743aaac8def.tar.gz
gcc-055df276d4e2b36c030223f39cd84743aaac8def.tar.bz2
tree.c (handle_dll_attribute): Check if node is of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.
2009-05-29 Kai Tietz <kai.tietz@onevision.com> * tree.c (handle_dll_attribute): Check if node is of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check. From-SVN: r147969
Diffstat (limited to 'gcc/tree.c')
-rw-r--r--gcc/tree.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree.c b/gcc/tree.c
index ddfa0a4..5e562a5 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -4169,7 +4169,8 @@ handle_dll_attribute (tree * pnode, tree name, tree args, int flags,
if (*no_add_attrs == false)
DECL_DLLIMPORT_P (node) = 1;
}
- else if (DECL_DECLARED_INLINE_P (node))
+ else if (TREE_CODE (node) == FUNCTION_DECL
+ && DECL_DECLARED_INLINE_P (node))
/* An exported function, even if inline, must be emitted. */
DECL_EXTERNAL (node) = 0;