Skip to content

Commit 11ea462

Browse files
committed
Register SwiftCompilerSources modules in libSwiftScan
1 parent b860c17 commit 11ea462

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tools/libSwiftScan/libSwiftScan.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
#include "swift/DependencyScan/StringUtils.h"
2222
#include "swift/DriverTool/DriverTool.h"
2323
#include "swift/Option/Options.h"
24+
#include "swift/SIL/SILBridging.h"
2425

2526
using namespace swift::dependencies;
2627

@@ -131,7 +132,8 @@ void swiftscan_scanner_cache_reset(swiftscan_scanner_t scanner) {
131132

132133
swiftscan_scanner_t swiftscan_scanner_create(void) {
133134
INITIALIZE_LLVM();
134-
initializeSwiftModules();
135+
if (!swiftModulesInitialized())
136+
initializeSwiftModules();
135137
return wrap(new DependencyScanningTool());
136138
}
137139

0 commit comments

Comments
 (0)