File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -153,7 +153,7 @@ void ObjCReason::describe(const Decl *D) const {
153
153
}
154
154
155
155
void ObjCReason::setAttrInvalid () const {
156
- if (requiresAttr (kind))
156
+ if (shouldInvalidateAttr (kind))
157
157
getAttr ()->setInvalid ();
158
158
}
159
159
Original file line number Diff line number Diff line change @@ -127,6 +127,14 @@ class ObjCReason {
127
127
}
128
128
}
129
129
130
+ // / If the declaration cannot be made \c @objc , should we invalidate the
131
+ // / attribute?
132
+ static bool shouldInvalidateAttr (Kind kind) {
133
+ if (kind == MemberOfObjCImplementationExtension)
134
+ return false ;
135
+ return requiresAttr (kind);
136
+ }
137
+
130
138
public:
131
139
// / Implicit conversion from the trivial reason kinds.
132
140
ObjCReason (Kind kind) : kind(kind) {
You can’t perform that action at this time.
0 commit comments