* decl.c (maybe_commonize_var): Fix thinko in last patch.
authorMark Mitchell <mark@codesourcery.com>
Mon, 28 Apr 2003 06:13:23 +0000 (06:13 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Mon, 28 Apr 2003 06:13:23 +0000 (06:13 +0000)
From-SVN: r66154

gcc/cp/ChangeLog
gcc/cp/decl.c

index d75773fc7ca8ca2f0c2748e6924a10bfcedd0871..84578bdcf1ee271e6655de6488c4e0b4f29edb49 100644 (file)
@@ -1,3 +1,7 @@
+2003-04-27  Mark Mitchell  <mark@codesourcery.com>
+
+       * decl.c (maybe_commonize_var): Fix thinko in last patch.
+
 2003-04-27  Mark Mitchell  <mark@codesourcery.com>
 
        PR c++/10506
index 575a612d8f6bef977ac37aeb48d7061996d22af5..6fe39c831335436088ec31424e64b888b6f92bd6 100644 (file)
@@ -7341,7 +7341,7 @@ maybe_commonize_var (tree decl)
       /* Unfortunately, import_export_decl has not always been called
         before the function is processed, so we cannot simply check
         DECL_COMDAT.  */ 
-      && (DECL_COMDAT (decl)
+      && (DECL_COMDAT (DECL_CONTEXT (decl))
          || ((DECL_DECLARED_INLINE_P (DECL_CONTEXT (decl))
               || DECL_TEMPLATE_INSTANTIATION (DECL_CONTEXT (decl)))
              && TREE_PUBLIC (DECL_CONTEXT (decl)))))