Merge pull request #81792 from sina-mahdavi/sina-mahdavi/fix-llvm-prefix-mapping-calls

fix calls to llvm prefix mapping functions to use space-separated opt…
This commit is contained in:
Argyrios Kyrtzidis
2025-06-25 13:19:21 -07:00
committed by GitHub
4 changed files with 12 additions and 10 deletions

View File

@@ -755,12 +755,8 @@ bool SwiftDependencyScanningService::setupCachingDependencyScanningService(
if (!ScannerPrefixMapper.empty()) {
Mapper = std::make_unique<llvm::PrefixMapper>();
SmallVector<llvm::MappedPrefix, 4> Prefixes;
if (auto E = llvm::MappedPrefix::transformJoined(ScannerPrefixMapper,
Prefixes)) {
Instance.getDiags().diagnose(SourceLoc(), diag::error_prefix_mapping,
toString(std::move(E)));
return true;
}
llvm::MappedPrefix::transformPairs(ScannerPrefixMapper,
Prefixes);
Mapper->addRange(Prefixes);
Mapper->sort();
}