aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInstance.cpp
diff options
context:
space:
mode:
authorJan Svoboda <jan_svoboda@apple.com>2025-04-04 10:11:14 -0700
committerGitHub <noreply@github.com>2025-04-04 10:11:14 -0700
commit1688c3062a56b4fca1f8ad28f2865df0ed8ca940 (patch)
tree54a166397652bb5c96fdd30caabf46765eb06f6e /clang/lib/Frontend/CompilerInstance.cpp
parent90cf2e31abdee050b5811155c86605935046b07e (diff)
downloadllvm-1688c3062a56b4fca1f8ad28f2865df0ed8ca940.zip
llvm-1688c3062a56b4fca1f8ad28f2865df0ed8ca940.tar.gz
llvm-1688c3062a56b4fca1f8ad28f2865df0ed8ca940.tar.bz2
[clang] Do not share ownership of `PreprocessorOptions` (#133467)
This PR makes it so that `CompilerInvocation` is the sole owner of the `PreprocessorOptions` instance.
Diffstat (limited to 'clang/lib/Frontend/CompilerInstance.cpp')
-rw-r--r--clang/lib/Frontend/CompilerInstance.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/CompilerInstance.cpp b/clang/lib/Frontend/CompilerInstance.cpp
index 91093d3..9cab17a 100644
--- a/clang/lib/Frontend/CompilerInstance.cpp
+++ b/clang/lib/Frontend/CompilerInstance.cpp
@@ -452,7 +452,7 @@ void CompilerInstance::createPreprocessor(TranslationUnitKind TUKind) {
HeaderSearch *HeaderInfo =
new HeaderSearch(getHeaderSearchOpts(), getSourceManager(),
getDiagnostics(), getLangOpts(), &getTarget());
- PP = std::make_shared<Preprocessor>(Invocation->getPreprocessorOptsPtr(),
+ PP = std::make_shared<Preprocessor>(Invocation->getPreprocessorOpts(),
getDiagnostics(), getLangOpts(),
getSourceManager(), *HeaderInfo, *this,
/*IdentifierInfoLookup=*/nullptr,