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 @@ -6363,6 +6363,9 @@ ConstructorDecl *NominalTypeDecl::getDefaultInitializer() const {
6363
6363
}
6364
6364
6365
6365
void NominalTypeDecl::synthesizeSemanticMembersIfNeeded (DeclName member) {
6366
+ if (isa<ProtocolDecl>(this ))
6367
+ return ;
6368
+
6366
6369
// Silently break cycles here because we can't be sure when and where a
6367
6370
// request to synthesize will come from yet.
6368
6371
// 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 @@ -2941,7 +2941,7 @@ static ArrayRef<Decl *> evaluateMembersRequest(
2941
2941
}
2942
2942
}
2943
2943
2944
- if (nominal) {
2944
+ if (nominal && !isa<ProtocolDecl>(nominal) ) {
2945
2945
// If the type conforms to Encodable or Decodable, even via an extension,
2946
2946
// the CodingKeys enum is synthesized as a member of the type itself.
2947
2947
// Force it into existence.
You can’t perform that action at this time.
0 commit comments