Skip to content

Commit 82bd81e

Browse files
committed
ClangImporter: Stop calling getAllConformances() on protocols
1 parent d9a3f2e commit 82bd81e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/ClangImporter/ImportDecl.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6598,8 +6598,8 @@ void SwiftDeclConverter::importObjCProtocols(
65986598
SmallVectorImpl<InheritedEntry> &inheritedTypes) {
65996599
SmallVector<ProtocolDecl *, 4> protocols;
66006600
llvm::SmallPtrSet<ProtocolDecl *, 4> knownProtocols;
6601-
if (auto nominal = dyn_cast<NominalTypeDecl>(decl)) {
6602-
nominal->getImplicitProtocols(protocols);
6601+
if (auto classDecl = dyn_cast<ClassDecl>(decl)) {
6602+
classDecl->getImplicitProtocols(protocols);
66036603
knownProtocols.insert(protocols.begin(), protocols.end());
66046604
}
66056605

0 commit comments

Comments
 (0)