diff options
author | Jan Svoboda <jan_svoboda@apple.com> | 2023-05-25 14:47:57 -0700 |
---|---|---|
committer | Jan Svoboda <jan_svoboda@apple.com> | 2023-05-30 13:54:06 -0700 |
commit | e19f352beee72d8fc30d9a5366eadd2372719fa3 (patch) | |
tree | f23f08bbeaa2b1a0ce4f9a1902654e43db3e47cb /clang/lib/Frontend/FrontendAction.cpp | |
parent | b1e5b28b8c4d8af294906ee27a62b28079d3f337 (diff) | |
download | llvm-e19f352beee72d8fc30d9a5366eadd2372719fa3.zip llvm-e19f352beee72d8fc30d9a5366eadd2372719fa3.tar.gz llvm-e19f352beee72d8fc30d9a5366eadd2372719fa3.tar.bz2 |
[clang][lex] NFCI: Use DirectoryEntryRef in Preprocessor::MainFileDir
This patch changes the type of `Preprocessor::MainFileDir` from `const DirectoryEntry *` to `Optional<DirectoryEntryRef>` in order to remove some calls to the deprecated `DirectoryEntry::getName()`.
Depends on D127658.
Reviewed By: bnbarham
Differential Revision: https://reviews.llvm.org/D127660
Diffstat (limited to 'clang/lib/Frontend/FrontendAction.cpp')
-rw-r--r-- | clang/lib/Frontend/FrontendAction.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/FrontendAction.cpp b/clang/lib/Frontend/FrontendAction.cpp index 77d03c4..a8dcdb4 100644 --- a/clang/lib/Frontend/FrontendAction.cpp +++ b/clang/lib/Frontend/FrontendAction.cpp @@ -511,7 +511,7 @@ static Module *prepareToBuildModule(CompilerInstance &CI, // Inform the preprocessor that includes from within the input buffer should // be resolved relative to the build directory of the module map file. - CI.getPreprocessor().setMainFileDir(M->Directory); + CI.getPreprocessor().setMainFileDir(*M->Directory); // If the module was inferred from a different module map (via an expanded // umbrella module definition), track that fact. |