File tree Expand file tree Collapse file tree 3 files changed +6
-1
lines changed Expand file tree Collapse file tree 3 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -6366,6 +6366,9 @@ ConstructorDecl *NominalTypeDecl::getDefaultInitializer() const {
6366
6366
}
6367
6367
6368
6368
void NominalTypeDecl::synthesizeSemanticMembersIfNeeded (DeclName member) {
6369
+ if (isa<ProtocolDecl>(this ))
6370
+ return ;
6371
+
6369
6372
// Silently break cycles here because we can't be sure when and where a
6370
6373
// request to synthesize will come from yet.
6371
6374
// FIXME: rdar://56844567
Original file line number Diff line number Diff line change @@ -1364,6 +1364,8 @@ evaluator::SideEffect
1364
1364
ResolveImplicitMemberRequest::evaluate (Evaluator &evaluator,
1365
1365
NominalTypeDecl *target,
1366
1366
ImplicitMemberAction action) const {
1367
+ ASSERT (!isa<ProtocolDecl>(target));
1368
+
1367
1369
// FIXME: This entire request is a layering violation made of smaller,
1368
1370
// finickier layering violations. See rdar://56844567
1369
1371
Original file line number Diff line number Diff line change @@ -2932,7 +2932,7 @@ static ArrayRef<Decl *> evaluateMembersRequest(
2932
2932
}
2933
2933
}
2934
2934
2935
- if (nominal) {
2935
+ if (nominal && !isa<ProtocolDecl>(nominal) ) {
2936
2936
// If the type conforms to Encodable or Decodable, even via an extension,
2937
2937
// the CodingKeys enum is synthesized as a member of the type itself.
2938
2938
// Force it into existence.
You can’t perform that action at this time.
0 commit comments