diff options
Diffstat (limited to 'clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp')
| -rw-r--r-- | clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp b/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp index b2b61de790e8..2a48c33ae253 100644 --- a/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp +++ b/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp @@ -127,9 +127,10 @@ public: /// For each input file discovered, check whether it's external path is in a /// stable directory. Traversal is stopped if the current module is not /// considered stable. - bool visitInputFile(StringRef FilenameAsRequested, StringRef Filename, - bool isSystem, bool isOverridden, - bool isExplicitModule) override { + bool visitInputFileAsRequested(StringRef FilenameAsRequested, + StringRef Filename, bool isSystem, + bool isOverridden, + bool isExplicitModule) override { if (StableDirs.empty()) return false; auto PrebuiltEntryIt = PrebuiltModulesASTMap.find(CurrentFile); @@ -448,9 +449,10 @@ public: // Use the dependency scanning optimized file system if requested to do so. if (DepFS) { - StringRef ModulesCachePath = - ScanInstance.getHeaderSearchOpts().ModuleCachePath; - + SmallString<256> ModulesCachePath; + CompilerInstance::normalizeModuleCachePath( + *FileMgr, ScanInstance.getHeaderSearchOpts().ModuleCachePath, + ModulesCachePath); DepFS->resetBypassedPathPrefix(); if (!ModulesCachePath.empty()) DepFS->setBypassedPathPrefix(ModulesCachePath); |
