[cfe-commits] r101168 - /cfe/trunk/lib/Sema/SemaDeclAttr.cpp

Fariborz Jahanian fjahanian at apple.com
Tue Apr 13 13:22:35 PDT 2010


Author: fjahanian
Date: Tue Apr 13 15:22:35 2010
New Revision: 101168

URL: http://llvm.org/viewvc/llvm-project?rev=101168&view=rev
Log:
Twik to radar 7839485. Do not attach weak_import attribute to class
for non-fragile abi on darwin.

Modified:
    cfe/trunk/lib/Sema/SemaDeclAttr.cpp

Modified: cfe/trunk/lib/Sema/SemaDeclAttr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclAttr.cpp?rev=101168&r1=101167&r2=101168&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclAttr.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclAttr.cpp Tue Apr 13 15:22:35 2010
@@ -900,12 +900,12 @@
     // We ignore weak import on properties and methods
     return;
   } else if (!(S.LangOpts.ObjCNonFragileABI && isa<ObjCInterfaceDecl>(D))) {
+    // Don't issue the warning for darwin as target; yet, ignore the attribute.
     if (S.Context.Target.getTriple().getOS() != llvm::Triple::Darwin ||
-        !isa<ObjCInterfaceDecl>(D)) {
-        S.Diag(Attr.getLoc(), diag::warn_attribute_wrong_decl_type)
+        !isa<ObjCInterfaceDecl>(D)) 
+      S.Diag(Attr.getLoc(), diag::warn_attribute_wrong_decl_type)
         << Attr.getName() << 2 /*variable and function*/;
       return;
-    }
   }
 
   // Merge should handle any subsequent violations.





More information about the cfe-commits mailing list