OSDN Git Service

2009-05-29 Kai Tietz <kai.tietz@onevision.com>
authorktietz <ktietz@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 29 May 2009 06:01:02 +0000 (06:01 +0000)
committerktietz <ktietz@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 29 May 2009 06:01:02 +0000 (06:01 +0000)
        * tree.c (handle_dll_attribute): Check if node is
        of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@147969 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/tree.c

index afd6cc8..e788ff6 100644 (file)
@@ -1,3 +1,8 @@
+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.
+
 2009-05-29  Richard Earnshaw  <rearnsha@arm.com>
 
        * config/arm/thumb2.md (thumb2_zero_extendsidi2): Add a split
index ddfa0a4..5e562a5 100644 (file)
@@ -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;