Adapt arguments for updated APIs

Forwarding data (differently) or passing trivial parameters.
This commit is contained in:
Jonas Hahnfeld 2023-07-10 08:44:20 +02:00 committed by jenkins
parent fae810094c
commit d5aec8274b
5 changed files with 9 additions and 5 deletions

View File

@ -1213,7 +1213,7 @@ namespace {
DumpModuleInfoListener Listener(Out);
HeaderSearchOptions &HSOpts =
PP.getHeaderSearchInfo().getHeaderSearchOpts();
ASTReader::readASTFileControlBlock(CurInput, FileMgr,
ASTReader::readASTFileControlBlock(CurInput, FileMgr, CI.getModuleCache(),
CI.getPCHContainerReader(),
/*FindModuleFileExtensions=*/true,
Listener,
@ -1499,6 +1499,7 @@ namespace {
PCHListener listener(Invocation);
if (ASTReader::readASTFileControlBlock(PCHFile,
CI->getFileManager(),
CI->getModuleCache(),
CI->getPCHContainerReader(),
false /*FindModuleFileExt*/,
listener,

View File

@ -210,7 +210,7 @@ namespace cling {
SourceLocation(), SourceLocation(),
&m_Context.Idents.get("__cling_N5"
+ std::to_string(m_UniqueNameCounter++)),
nullptr);
/*PrevDecl=*/nullptr, /*Nested=*/false);
//NS->setImplicit();
m_TU->addDecl(NS);
T->setDefinitionShadowNS(NS);

View File

@ -317,6 +317,7 @@ namespace cling {
auto CG
= std::unique_ptr<clang::CodeGenerator>(CreateLLVMCodeGen(Diag,
makeModuleName(),
&m_CI->getVirtualFileSystem(),
m_CI->getHeaderSearchOpts(),
m_CI->getPreprocessorOpts(),
m_CI->getCodeGenOpts(),
@ -927,7 +928,8 @@ namespace cling {
Sema::LocalEagerInstantiationScope LocalInstantiations(S);
Parser::DeclGroupPtrTy ADecl;
while (!m_Parser->ParseTopLevelDecl(ADecl)) {
Sema::ModuleImportState IS = Sema::ModuleImportState::NotACXX20Module;
while (!m_Parser->ParseTopLevelDecl(ADecl, IS)) {
// If we got a null return and something *was* parsed, ignore it. This
// is due to a top-level semicolon, an action override, or a parse error
// skipping something.

View File

@ -872,7 +872,8 @@ namespace cling {
Preprocessor& PP = getCI()->getPreprocessor();
HeaderSearch &HS = PP.getHeaderSearchInfo();
if (Module *M = HS.lookupModule(moduleName, /*AllowSearch*/true,
if (Module *M = HS.lookupModule(moduleName, SourceLocation(),
/*AllowSearch*/true,
/*AllowExtraSearch*/ true))
return loadModule(M, complain);

View File

@ -329,7 +329,7 @@ namespace cling {
// Wrap both the existing source and our source. We give our own
// source preference to the existing one.
IntrusiveRefCntPtr<ExternalASTSource> S;
S = new MultiplexExternalSemaSource(*m_ExternalSemaSource, *wrapper);
S = new MultiplexExternalSemaSource(m_ExternalSemaSource, wrapper);
Ctx.setExternalSource(S);
} else {