aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/clang/Basic/Attr.td3
-rw-r--r--lib/Sema/SemaDeclAttr.cpp4
2 files changed, 4 insertions, 3 deletions
diff --git a/include/clang/Basic/Attr.td b/include/clang/Basic/Attr.td
index 9289bd286e..4db8ef2804 100644
--- a/include/clang/Basic/Attr.td
+++ b/include/clang/Basic/Attr.td
@@ -54,6 +54,7 @@ class ExprArgument<string name> : Argument<name>;
class FunctionArgument<string name> : Argument<name>;
class TypeArgument<string name> : Argument<name>;
class UnsignedArgument<string name> : Argument<name>;
+class SourceLocArgument<string name> : Argument<name>;
class VariadicUnsignedArgument<string name> : Argument<name>;
class VariadicExprArgument<string name> : Argument<name>;
@@ -287,7 +288,7 @@ def IBOutlet : InheritableAttr {
def IBOutletCollection : InheritableAttr {
let Spellings = ["iboutletcollection"];
- let Args = [TypeArgument<"InterFace">];
+ let Args = [TypeArgument<"InterFace">, SourceLocArgument<"InterFaceLoc">];
}
def Malloc : InheritableAttr {
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp
index 7c7e3abf16..a887ce8ac3 100644
--- a/lib/Sema/SemaDeclAttr.cpp
+++ b/lib/Sema/SemaDeclAttr.cpp
@@ -815,8 +815,8 @@ static void handleIBOutletCollection(Sema &S, Decl *D,
S.Diag(Attr.getLoc(), diag::err_iboutletcollection_type) << II;
return;
}
- D->addAttr(::new (S.Context) IBOutletCollectionAttr(Attr.getRange(), S.Context,
- QT));
+ D->addAttr(::new (S.Context) IBOutletCollectionAttr(Attr.getRange(),S.Context,
+ QT, Attr.getParameterLoc()));
}
static void possibleTransparentUnionPointerType(QualType &T) {