File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed
validation-test/Serialization/AllowErrors Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -1460,7 +1460,8 @@ void Serializer::writeASTBlockEntity(
1460
1460
data.push_back (addDeclRef (req));
1461
1461
data.push_back (addDeclRef (witness.getDecl ()));
1462
1462
assert (witness.getDecl () || req->getAttrs ().hasAttribute <OptionalAttr>()
1463
- || req->getAttrs ().isUnavailable (req->getASTContext ()));
1463
+ || req->getAttrs ().isUnavailable (req->getASTContext ())
1464
+ || allowCompilerErrors ());
1464
1465
1465
1466
// If there is no witness, we're done.
1466
1467
if (!witness.getDecl ()) return ;
Original file line number Diff line number Diff line change
1
+ // RUN: %empty-directory(%t)
2
+
3
+ // RUN: %target-swift-frontend -module-name errors -emit-module -o %t/errors.swiftmodule -experimental-allow-module-with-compiler-errors %s
4
+
5
+ public protocol SomeProto {
6
+ init ( from: SomeProto )
7
+ }
8
+
9
+ struct A { }
10
+ struct B : SomeProto {
11
+ let a : A
12
+ }
13
+
14
+ let thing = B ( a: A ( ) )
You can’t perform that action at this time.
0 commit comments