mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Dependency Scanning] Introduce a new constructor for dummy source modules
Instead of passing in a bunch of dummy/empty data.
This commit is contained in:
@@ -1161,13 +1161,13 @@ void ModuleDependencyScanner::discoverCrossImportOverlayDependencies(
|
||||
|
||||
// Construct a dummy main to resolve the newly discovered cross import
|
||||
// overlays.
|
||||
StringRef dummyMainName = "DummyMainModuleForResolvingCrossImportOverlays";
|
||||
StringRef dummyMainName = "MainModuleCrossImportOverlays";
|
||||
auto dummyMainID = ModuleDependencyID{dummyMainName.str(),
|
||||
ModuleDependencyKind::SwiftSource};
|
||||
auto actualMainID = ModuleDependencyID{mainModuleName.str(),
|
||||
ModuleDependencyKind::SwiftSource};
|
||||
auto dummyMainDependencies =
|
||||
ModuleDependencyInfo::forSwiftSourceModule({}, {}, {}, {}, {}, {});
|
||||
ModuleDependencyInfo::forSwiftSourceModule();
|
||||
std::for_each(newOverlays.begin(), newOverlays.end(),
|
||||
[&](Identifier modName) {
|
||||
dummyMainDependencies.addModuleImport(modName.str());
|
||||
|
||||
Reference in New Issue
Block a user