Skip to content

Commit 1c101ca

Browse files
committed
Swift: Fix dataset check errors by outputting more unavailable decls
1 parent 294de74 commit 1c101ca

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

swift/extractor/SwiftExtractor.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,8 @@ static std::unordered_set<swift::ModuleDecl*> extractDeclarations(
170170
bodyEmissionStrategy);
171171
auto topLevelDecls = getTopLevelDecls(module, primaryFile, lazyDeclaration);
172172
for (auto decl : topLevelDecls) {
173-
if (decl->isUnavailable() && !llvm::isa<swift::NominalTypeDecl>(decl)) {
173+
if (decl->isUnavailable() && !llvm::isa<swift::NominalTypeDecl>(decl) &&
174+
!llvm::isa<swift::VarDecl>(decl)) {
174175
continue;
175176
}
176177
visitor.extract(decl);

0 commit comments

Comments
 (0)