Skip to content

Commit aa0454a

Browse files
authored
Merge pull request #19753 from rudkx/fix-extension-decl-comparison
2 parents e94450e + b08060b commit aa0454a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/Sema/CSSolver.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1733,7 +1733,8 @@ void ConstraintSystem::partitionDisjunction(
17331733
}
17341734

17351735
if (auto *extensionDecl = dyn_cast<ExtensionDecl>(parentDecl)) {
1736-
if (static_cast<Decl *>(extensionDecl) == designatedProtocol) {
1736+
parentDecl = extensionDecl->getExtendedNominal();
1737+
if (parentDecl == designatedProtocol) {
17371738
definedInExtensionOfDesignatedType.push_back(index);
17381739
return true;
17391740
}

0 commit comments

Comments
 (0)