There was an error while loading. Please reload this page.
1 parent 20f36e0 commit ba5654fCopy full SHA for ba5654f
1 file changed
swift/extractor/infra/SwiftBodyEmissionStrategy.h
@@ -13,9 +13,11 @@ class SwiftBodyEmissionStrategy {
13
: currentModule(currentModule),
14
currentPrimarySourceFile(currentPrimarySourceFile),
15
currentLazyDeclaration(currentLazyDeclaration) {
16
- llvm::SmallVector<swift::Decl*> decls;
17
- currentModule.getTopLevelDecls(decls);
18
- currentTopLevelDecls.insert(decls.begin(), decls.end());
+ if (!currentLazyDeclaration) {
+ llvm::SmallVector<swift::Decl*> decls;
+ currentModule.getTopLevelDecls(decls);
19
+ currentTopLevelDecls.insert(decls.begin(), decls.end());
20
+ }
21
}
22
23
bool shouldEmitDeclBody(const swift::Decl& decl);
0 commit comments