mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Dependency Scanning] Teach dependency scanner to resolve optional dependencies of a module
This commit is contained in:
@@ -89,6 +89,12 @@ void ModuleDependencyInfo::addModuleDependency(ModuleDependencyID dependencyID)
|
||||
storage->resolvedModuleDependencies.push_back(dependencyID);
|
||||
}
|
||||
|
||||
void ModuleDependencyInfo::addOptionalModuleImport(
|
||||
StringRef module, llvm::StringSet<> *alreadyAddedModules) {
|
||||
if (!alreadyAddedModules || alreadyAddedModules->insert(module).second)
|
||||
storage->optionalModuleImports.push_back(module.str());
|
||||
}
|
||||
|
||||
void ModuleDependencyInfo::addModuleImport(
|
||||
StringRef module, llvm::StringSet<> *alreadyAddedModules) {
|
||||
if (!alreadyAddedModules || alreadyAddedModules->insert(module).second)
|
||||
|
||||
Reference in New Issue
Block a user