LLDB  mainline
Public Member Functions | Static Public Member Functions | Private Attributes | Static Private Attributes | List of all members
lldb_private::ClangExternalASTSourceCallbacks Class Reference

#include <ClangExternalASTSourceCallbacks.h>

Inheritance diagram for lldb_private::ClangExternalASTSourceCallbacks:
Inheritance graph
[legend]
Collaboration diagram for lldb_private::ClangExternalASTSourceCallbacks:
Collaboration graph
[legend]

Public Member Functions

bool isA (const void *ClassID) const override
 LLVM RTTI support. More...
 
 ClangExternalASTSourceCallbacks (TypeSystemClang &ast)
 
void FindExternalLexicalDecls (const clang::DeclContext *DC, llvm::function_ref< bool(clang::Decl::Kind)> IsKindWeWant, llvm::SmallVectorImpl< clang::Decl * > &Result) override
 
bool FindExternalVisibleDeclsByName (const clang::DeclContext *DC, clang::DeclarationName Name) override
 
void CompleteType (clang::TagDecl *tag_decl) override
 
void CompleteType (clang::ObjCInterfaceDecl *objc_decl) override
 
bool layoutRecordType (const clang::RecordDecl *Record, uint64_t &Size, uint64_t &Alignment, llvm::DenseMap< const clang::FieldDecl *, uint64_t > &FieldOffsets, llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &BaseOffsets, llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &VirtualBaseOffsets) override
 
TypeSystemClangGetTypeSystem () const
 
llvm::Optional< clang::ASTSourceDescriptor > getSourceDescriptor (unsigned ID) override
 Module-related methods. More...
 
clang::Module * getModule (unsigned ID) override
 
OptionalClangModuleID RegisterModule (clang::Module *module)
 
OptionalClangModuleID GetIDForModule (clang::Module *module)
 

Static Public Member Functions

static bool classof (const clang::ExternalASTSource *s)
 

Private Attributes

TypeSystemClangm_ast
 
std::vector< clang::Module * > m_modules
 
llvm::DenseMap< clang::Module *, unsigned > m_ids
 

Static Private Attributes

static char ID
 LLVM RTTI support. More...
 

Detailed Description

Definition at line 17 of file ClangExternalASTSourceCallbacks.h.

Constructor & Destructor Documentation

◆ ClangExternalASTSourceCallbacks()

lldb_private::ClangExternalASTSourceCallbacks::ClangExternalASTSourceCallbacks ( TypeSystemClang ast)
inline

Definition at line 26 of file ClangExternalASTSourceCallbacks.h.

Member Function Documentation

◆ classof()

static bool lldb_private::ClangExternalASTSourceCallbacks::classof ( const clang::ExternalASTSource *  s)
inlinestatic

Definition at line 24 of file ClangExternalASTSourceCallbacks.h.

References ID.

◆ CompleteType() [1/2]

void ClangExternalASTSourceCallbacks::CompleteType ( clang::ObjCInterfaceDecl *  objc_decl)
override

◆ CompleteType() [2/2]

void ClangExternalASTSourceCallbacks::CompleteType ( clang::TagDecl *  tag_decl)
override

◆ FindExternalLexicalDecls()

void ClangExternalASTSourceCallbacks::FindExternalLexicalDecls ( const clang::DeclContext *  DC,
llvm::function_ref< bool(clang::Decl::Kind)>  IsKindWeWant,
llvm::SmallVectorImpl< clang::Decl * > &  Result 
)
override

Definition at line 38 of file ClangExternalASTSourceCallbacks.cpp.

References CompleteType().

◆ FindExternalVisibleDeclsByName()

bool ClangExternalASTSourceCallbacks::FindExternalVisibleDeclsByName ( const clang::DeclContext *  DC,
clang::DeclarationName  Name 
)
override

Definition at line 50 of file ClangExternalASTSourceCallbacks.cpp.

◆ GetIDForModule()

OptionalClangModuleID ClangExternalASTSourceCallbacks::GetIDForModule ( clang::Module *  module)

Definition at line 86 of file ClangExternalASTSourceCallbacks.cpp.

References m_ids.

Referenced by RemapModule().

◆ getModule()

clang::Module * ClangExternalASTSourceCallbacks::getModule ( unsigned  ID)
override

Definition at line 79 of file ClangExternalASTSourceCallbacks.cpp.

References m_modules.

Referenced by getSourceDescriptor(), and RemapModule().

◆ getSourceDescriptor()

llvm::Optional< clang::ASTSourceDescriptor > ClangExternalASTSourceCallbacks::getSourceDescriptor ( unsigned  ID)
override

Module-related methods.

Definition at line 73 of file ClangExternalASTSourceCallbacks.cpp.

References getModule().

◆ GetTypeSystem()

TypeSystemClang& lldb_private::ClangExternalASTSourceCallbacks::GetTypeSystem ( ) const
inline

Definition at line 48 of file ClangExternalASTSourceCallbacks.h.

References m_ast.

Referenced by RemapModule().

◆ isA()

bool lldb_private::ClangExternalASTSourceCallbacks::isA ( const void *  ClassID) const
inlineoverride

LLVM RTTI support.

Definition at line 23 of file ClangExternalASTSourceCallbacks.h.

References ID.

◆ layoutRecordType()

bool ClangExternalASTSourceCallbacks::layoutRecordType ( const clang::RecordDecl *  Record,
uint64_t &  Size,
uint64_t &  Alignment,
llvm::DenseMap< const clang::FieldDecl *, uint64_t > &  FieldOffsets,
llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &  BaseOffsets,
llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &  VirtualBaseOffsets 
)
override

◆ RegisterModule()

OptionalClangModuleID ClangExternalASTSourceCallbacks::RegisterModule ( clang::Module *  module)

Definition at line 65 of file ClangExternalASTSourceCallbacks.cpp.

References m_ids, and m_modules.

Member Data Documentation

◆ ID

char ClangExternalASTSourceCallbacks::ID
staticprivate

LLVM RTTI support.

Definition at line 19 of file ClangExternalASTSourceCallbacks.h.

Referenced by classof(), and isA().

◆ m_ast

TypeSystemClang& lldb_private::ClangExternalASTSourceCallbacks::m_ast
private

Definition at line 59 of file ClangExternalASTSourceCallbacks.h.

Referenced by CompleteType(), GetTypeSystem(), and layoutRecordType().

◆ m_ids

llvm::DenseMap<clang::Module *, unsigned> lldb_private::ClangExternalASTSourceCallbacks::m_ids
private

Definition at line 61 of file ClangExternalASTSourceCallbacks.h.

Referenced by GetIDForModule(), and RegisterModule().

◆ m_modules

std::vector<clang::Module *> lldb_private::ClangExternalASTSourceCallbacks::m_modules
private

Definition at line 60 of file ClangExternalASTSourceCallbacks.h.

Referenced by getModule(), and RegisterModule().


The documentation for this class was generated from the following files: