diff options
author | Jan Svoboda <jan_svoboda@apple.com> | 2023-05-25 12:38:45 -0700 |
---|---|---|
committer | Jan Svoboda <jan_svoboda@apple.com> | 2023-05-30 13:54:06 -0700 |
commit | 769d282d7292d14591a721ee967962736160095e (patch) | |
tree | 4fad903fe329c8e8443108aeff690171f0e677b6 /clang/lib/Lex/ModuleMap.cpp | |
parent | 9e8a412cb37d2a1201bd33878fce0993587ef335 (diff) | |
download | llvm-769d282d7292d14591a721ee967962736160095e.zip llvm-769d282d7292d14591a721ee967962736160095e.tar.gz llvm-769d282d7292d14591a721ee967962736160095e.tar.bz2 |
[clang][lex] NFCI: Use FileEntryRef in ModuleMap::{load,lookup}ModuleMap()
This patch changes the return/argument types of `ModuleMap::{load,lookup}ModuleMap()` from `const FileEntry *` to `FileEntryRef` in order to remove uses of the deprecated `DirectoryEntry::getName()`.
Reviewed By: bnbarham
Differential Revision: https://reviews.llvm.org/D127647
Diffstat (limited to 'clang/lib/Lex/ModuleMap.cpp')
-rw-r--r-- | clang/lib/Lex/ModuleMap.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Lex/ModuleMap.cpp b/clang/lib/Lex/ModuleMap.cpp index 0db7ebf..adaad64 100644 --- a/clang/lib/Lex/ModuleMap.cpp +++ b/clang/lib/Lex/ModuleMap.cpp @@ -1019,9 +1019,9 @@ Module *ModuleMap::inferFrameworkModule(const DirectoryEntry *FrameworkDir, // We haven't looked here before. Load a module map, if there is // one. bool IsFrameworkDir = Parent.endswith(".framework"); - if (const FileEntry *ModMapFile = - HeaderInfo.lookupModuleMapFile(*ParentDir, IsFrameworkDir)) { - parseModuleMapFile(ModMapFile, Attrs.IsSystem, *ParentDir); + if (OptionalFileEntryRef ModMapFile = + HeaderInfo.lookupModuleMapFile(*ParentDir, IsFrameworkDir)) { + parseModuleMapFile(*ModMapFile, Attrs.IsSystem, *ParentDir); inferred = InferredDirectories.find(*ParentDir); } |