File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -1312,6 +1312,8 @@ void TypeChecker::checkIgnoredExpr(Expr *E) {
1312
1312
return checkIgnoredExpr (IIO->getSubExpr ());
1313
1313
if (auto *C = dyn_cast<CallExpr>(OEE->getSubExpr ()))
1314
1314
return checkIgnoredExpr (C);
1315
+ if (auto *OE = dyn_cast<OpenExistentialExpr>(OEE->getSubExpr ()))
1316
+ return checkIgnoredExpr (OE);
1315
1317
}
1316
1318
1317
1319
if (auto *LE = dyn_cast<LiteralExpr>(valueE)) {
Original file line number Diff line number Diff line change @@ -194,3 +194,20 @@ class SR7562_B : SR7562_A {}
194
194
195
195
SR7562_A ( input: 10 ) // okay
196
196
SR7562_B ( input: 10 ) // okay
197
+
198
+ protocol FooProtocol { }
199
+
200
+ extension FooProtocol {
201
+ @discardableResult
202
+ static func returnSomething( ) -> Bool ? {
203
+ return true
204
+ }
205
+ }
206
+
207
+ class Foo {
208
+ var myOptionalFooProtocol : FooProtocol . Type ?
209
+
210
+ func doSomething( ) {
211
+ myOptionalFooProtocol? . returnSomething ( ) // okay
212
+ }
213
+ }
You can’t perform that action at this time.
0 commit comments