r196107 - Switching the ibaction attribute handler to the generalized handler. No functional change intended.

Aaron Ballman aaron at aaronballman.com
Mon Dec 2 07:13:14 PST 2013


Author: aaronballman
Date: Mon Dec  2 09:13:14 2013
New Revision: 196107

URL: http://llvm.org/viewvc/llvm-project?rev=196107&view=rev
Log:
Switching the ibaction attribute handler to the generalized handler. No functional change intended.

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=196107&r1=196106&r2=196107&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclAttr.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclAttr.cpp Mon Dec  2 09:13:14 2013
@@ -1068,11 +1068,6 @@ static void handlePackedAttr(Sema &S, De
     S.Diag(Attr.getLoc(), diag::warn_attribute_ignored) << Attr.getName();
 }
 
-static void handleIBAction(Sema &S, Decl *D, const AttributeList &Attr) {
-  D->addAttr(::new (S.Context) IBActionAttr(Attr.getRange(), S.Context,
-                                        Attr.getAttributeSpellingListIndex()));
-}
-
 static bool checkIBOutletCommon(Sema &S, Decl *D, const AttributeList &Attr) {
   // The IBOutlet/IBOutletCollection attributes only apply to instance
   // variables or properties of Objective-C classes.  The outlet must also
@@ -4030,7 +4025,8 @@ static void ProcessDeclAttribute(Sema &S
     return;
 
   switch (Attr.getKind()) {
-  case AttributeList::AT_IBAction:    handleIBAction(S, D, Attr); break;
+  case AttributeList::AT_IBAction:
+    handleSimpleAttribute<IBActionAttr>(S, D, Attr); break;
   case AttributeList::AT_IBOutlet:    handleIBOutlet(S, D, Attr); break;
   case AttributeList::AT_IBOutletCollection:
     handleIBOutletCollection(S, D, Attr); break;





More information about the cfe-commits mailing list