class ChainedASTReaderListener

Declaration

class ChainedASTReaderListener : public ASTReaderListener { /* full declaration omitted */ };

Description

Simple wrapper class for chaining listeners.

Declared at: clang/include/clang/Serialization/ASTReader.h:230

Inherits from: ASTReaderListener

Member Variables

private std::unique_ptr<ASTReaderListener> First
private std::unique_ptr<ASTReaderListener> Second

Method Overview

Inherited from ASTReaderListener:

Methods

ChainedASTReaderListener(
    std::unique_ptr<ASTReaderListener> First,
    std::unique_ptr<ASTReaderListener> Second)

Description

Takes ownership of \p First and \p Second.

Declared at: clang/include/clang/Serialization/ASTReader.h:236

Parameters

std::unique_ptr<ASTReaderListener> First
std::unique_ptr<ASTReaderListener> Second

void ReadCounter(
    const serialization::ModuleFile& M,
    unsigned int Value)

Description

Receives __COUNTER__ value.

Declared at: clang/include/clang/Serialization/ASTReader.h:262

Parameters

const serialization::ModuleFile& M
unsigned int Value

bool ReadDiagnosticOptions(
    IntrusiveRefCntPtr<clang::DiagnosticOptions>
        DiagOpts,
    bool Complain)

Description

Receives the diagnostic options.

Declared at: clang/include/clang/Serialization/ASTReader.h:250

Parameters

IntrusiveRefCntPtr<clang::DiagnosticOptions> DiagOpts
bool Complain

Returns

true to indicate the diagnostic options are invalid, or false otherwise.

bool ReadFileSystemOptions(
    const clang::FileSystemOptions& FSOpts,
    bool Complain)

Description

Receives the file system options.

Declared at: clang/include/clang/Serialization/ASTReader.h:252

Parameters

const clang::FileSystemOptions& FSOpts
bool Complain

Returns

true to indicate the file system options are invalid, or false otherwise.

bool ReadFullVersionInformation(
    llvm::StringRef FullVersion)

Description

Receives the full Clang version information.

Declared at: clang/include/clang/Serialization/ASTReader.h:243

Parameters

llvm::StringRef FullVersion

Returns

true to indicate that the version is invalid. Subclasses should generally defer to this implementation.

bool ReadHeaderSearchOptions(
    const clang::HeaderSearchOptions& HSOpts,
    llvm::StringRef SpecificModuleCachePath,
    bool Complain)

Description

Receives the header search options.

Declared at: clang/include/clang/Serialization/ASTReader.h:255

Parameters

const clang::HeaderSearchOptions& HSOpts
llvm::StringRef SpecificModuleCachePath
bool Complain

Returns

true to indicate the header search options are invalid, or false otherwise.

bool ReadLanguageOptions(
    const clang::LangOptions& LangOpts,
    bool Complain,
    bool AllowCompatibleDifferences)

Description

Receives the language options.

Declared at: clang/include/clang/Serialization/ASTReader.h:246

Parameters

const clang::LangOptions& LangOpts
bool Complain
bool AllowCompatibleDifferences

Returns

true to indicate the options are invalid or false otherwise.

void ReadModuleMapFile(
    llvm::StringRef ModuleMapPath)

Declared at: clang/include/clang/Serialization/ASTReader.h:245

Parameters

llvm::StringRef ModuleMapPath

void ReadModuleName(llvm::StringRef ModuleName)

Declared at: clang/include/clang/Serialization/ASTReader.h:244

Parameters

llvm::StringRef ModuleName

bool ReadPreprocessorOptions(
    const clang::PreprocessorOptions& PPOpts,
    bool Complain,
    std::string& SuggestedPredefines)

Description

Receives the preprocessor options.

Declared at: clang/include/clang/Serialization/ASTReader.h:258

Parameters

const clang::PreprocessorOptions& PPOpts
bool Complain
std::string& SuggestedPredefines
Can be filled in with the set of predefines that are suggested by the preprocessor options. Typically only used when loading a precompiled header.

Returns

true to indicate the preprocessor options are invalid, or false otherwise.

bool ReadTargetOptions(
    const clang::TargetOptions& TargetOpts,
    bool Complain,
    bool AllowCompatibleDifferences)

Description

Receives the target options.

Declared at: clang/include/clang/Serialization/ASTReader.h:248

Parameters

const clang::TargetOptions& TargetOpts
bool Complain
bool AllowCompatibleDifferences

Returns

true to indicate the target options are invalid, or false otherwise.

bool needsInputFileVisitation()

Description

Returns true if this \c ASTReaderListener wants to receive the input files of the AST file via \c visitInputFile, false otherwise.

Declared at: clang/include/clang/Serialization/ASTReader.h:263

bool needsSystemInputFileVisitation()

Description

Returns true if this \c ASTReaderListener wants to receive the system input files of the AST file via \c visitInputFile, false otherwise.

Declared at: clang/include/clang/Serialization/ASTReader.h:264

void readModuleFileExtension(
    const clang::ModuleFileExtensionMetadata&
        Metadata)

Description

Indicates that a particular module file extension has been read.

Declared at: clang/include/clang/Serialization/ASTReader.h:269

Parameters

const clang::ModuleFileExtensionMetadata& Metadata

std::unique_ptr<ASTReaderListener> takeFirst()

Declared at: clang/include/clang/Serialization/ASTReader.h:240

std::unique_ptr<ASTReaderListener> takeSecond()

Declared at: clang/include/clang/Serialization/ASTReader.h:241

bool visitInputFile(llvm::StringRef Filename,
                    bool isSystem,
                    bool isOverridden,
                    bool isExplicitModule)

Description

if \c needsInputFileVisitation returns true, this is called for each non-system input file of the AST File. If\c needsSystemInputFileVisitation is true, then it is called for all system input files as well.

Declared at: clang/include/clang/Serialization/ASTReader.h:267

Parameters

llvm::StringRef Filename
bool isSystem
bool isOverridden
bool isExplicitModule

Returns

true to continue receiving the next input file, false to stop.

void visitModuleFile(
    llvm::StringRef Filename,
    serialization::ModuleKind Kind)

Description

This is called for each AST file loaded.

Declared at: clang/include/clang/Serialization/ASTReader.h:265

Parameters

llvm::StringRef Filename
serialization::ModuleKind Kind