From 1688c3062a56b4fca1f8ad28f2865df0ed8ca940 Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Fri, 4 Apr 2025 10:11:14 -0700 Subject: [clang] Do not share ownership of `PreprocessorOptions` (#133467) This PR makes it so that `CompilerInvocation` is the sole owner of the `PreprocessorOptions` instance. --- clang/unittests/Lex/LexerTest.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'clang/unittests/Lex/LexerTest.cpp') diff --git a/clang/unittests/Lex/LexerTest.cpp b/clang/unittests/Lex/LexerTest.cpp index 96a0717..3bbc571 100644 --- a/clang/unittests/Lex/LexerTest.cpp +++ b/clang/unittests/Lex/LexerTest.cpp @@ -59,9 +59,9 @@ protected: HeaderSearchOptions HSOpts; HeaderSearch HeaderInfo(HSOpts, SourceMgr, Diags, LangOpts, Target.get()); + PreprocessorOptions PPOpts; std::unique_ptr PP = std::make_unique( - std::make_shared(), Diags, LangOpts, SourceMgr, - HeaderInfo, ModLoader, + PPOpts, Diags, LangOpts, SourceMgr, HeaderInfo, ModLoader, /*IILookup =*/nullptr, /*OwnsHeaderSearch =*/false); PP->Initialize(*Target); -- cgit v1.1