Skip to content

Commit c6b264f

Browse files
committed
ASTVerifier: Remove signature conformances verification
1 parent c90b8e6 commit c6b264f

File tree

1 file changed

+0
-34
lines changed

1 file changed

+0
-34
lines changed

lib/AST/ASTVerifier.cpp

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -2878,40 +2878,6 @@ class Verifier : public ASTWalker {
28782878
continue;
28792879
}
28802880
}
2881-
2882-
// Make sure we have the right signature conformances.
2883-
if (!normal->isInvalid()){
2884-
auto conformances = normal->getSignatureConformances();
2885-
unsigned idx = 0;
2886-
auto reqs = proto->getRequirementSignature().getRequirements();
2887-
for (const auto &req : reqs) {
2888-
if (req.getKind() != RequirementKind::Conformance)
2889-
continue;
2890-
2891-
if (idx >= conformances.size()) {
2892-
Out << "error: not enough conformances for requirement signature\n";
2893-
normal->dump(Out);
2894-
abort();
2895-
}
2896-
2897-
auto reqProto = req.getProtocolDecl();
2898-
if (reqProto != conformances[idx].getRequirement()) {
2899-
Out << "error: wrong protocol in signature conformances: have "
2900-
<< conformances[idx].getRequirement()->getName().str()
2901-
<< ", expected " << reqProto->getName().str()<< "\n";
2902-
normal->dump(Out);
2903-
abort();
2904-
}
2905-
2906-
++idx;
2907-
}
2908-
2909-
if (idx != conformances.size()) {
2910-
Out << "error: too many conformances for requirement signature\n";
2911-
normal->dump(Out);
2912-
abort();
2913-
}
2914-
}
29152881
}
29162882

29172883
void verifyChecked(GenericTypeDecl *generic) {

0 commit comments

Comments
 (0)