aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/ASTUnit.cpp
diff options
context:
space:
mode:
authorChuanqi Xu <yedeng.yd@linux.alibaba.com>2023-05-16 11:22:02 +0800
committerChuanqi Xu <yedeng.yd@linux.alibaba.com>2023-05-16 11:24:35 +0800
commit88a720d19479e4cad186f00a9911714c3d77303a (patch)
tree52da0ae0c5230970cb85ced3e59065406dd291cb /clang/lib/Frontend/ASTUnit.cpp
parent369e8762b4d658e6e8f8310200aadf043bd7f01e (diff)
downloadllvm-88a720d19479e4cad186f00a9911714c3d77303a.zip
llvm-88a720d19479e4cad186f00a9911714c3d77303a.tar.gz
llvm-88a720d19479e4cad186f00a9911714c3d77303a.tar.bz2
[NFC] [C++20] [Modules] Rename ASTContext::getNamedModuleForCodeGen to ASTContext::getCurrentNamedModule
The original name "ASTContext::getNamedModuleForCodeGen" is not properly reflecting the usage of the interface. This interface can be used to judge the current module unit in both sema analysis and code generation. So the original name was not so correct.
Diffstat (limited to 'clang/lib/Frontend/ASTUnit.cpp')
-rw-r--r--clang/lib/Frontend/ASTUnit.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/ASTUnit.cpp b/clang/lib/Frontend/ASTUnit.cpp
index bda49fb..b1e7db1 100644
--- a/clang/lib/Frontend/ASTUnit.cpp
+++ b/clang/lib/Frontend/ASTUnit.cpp
@@ -879,7 +879,7 @@ std::unique_ptr<ASTUnit> ASTUnit::LoadFromASTFile(
Module *M = HeaderInfo.lookupModule(AST->getLangOpts().CurrentModule);
if (M && AST->getLangOpts().isCompilingModule() && M->isModulePurview())
- AST->Ctx->setNamedModuleForCodeGen(M);
+ AST->Ctx->setCurrentNamedModule(M);
// Create an AST consumer, even though it isn't used.
if (ToLoad >= LoadASTOnly)