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

A TypeSystem implementation based on Clang. More...

#include <TypeSystemClang.h>

Inheritance diagram for lldb_private::TypeSystemClang:
Inheritance graph
[legend]

Classes

class  TemplateParameterInfos
 

Public Types

typedef void(* CompleteTagDeclCallback) (void *baton, clang::TagDecl *)
 
typedef void(* CompleteObjCInterfaceDeclCallback) (void *baton, clang::ObjCInterfaceDecl *)
 

Public Member Functions

bool isA (const void *ClassID) const override
 
 TypeSystemClang (llvm::StringRef name, llvm::Triple triple)
 Constructs a TypeSystemClang with an ASTContext using the given triple.
 
 TypeSystemClang (llvm::StringRef name, clang::ASTContext &existing_ctxt)
 Constructs a TypeSystemClang that uses an existing ASTContext internally.
 
 ~TypeSystemClang () override
 
void Finalize () override
 Free up any resources associated with this TypeSystem.
 
llvm::StringRef GetPluginName () override
 
llvm::StringRef getDisplayName () const
 Returns the display name of this TypeSystemClang that indicates what purpose it serves in LLDB.
 
clang::ASTContext & getASTContext ()
 Returns the clang::ASTContext instance managed by this TypeSystemClang.
 
clang::MangleContext * getMangleContext ()
 
std::shared_ptr< clang::TargetOptions > & getTargetOptions ()
 
clang::TargetInfo * getTargetInfo ()
 
void setSema (clang::Sema *s)
 
clang::Sema * getSema ()
 
const char * GetTargetTriple ()
 
void SetExternalSource (llvm::IntrusiveRefCntPtr< clang::ExternalASTSource > &ast_source_up)
 
bool GetCompleteDecl (clang::Decl *decl)
 
void SetMetadataAsUserID (const clang::Decl *decl, lldb::user_id_t user_id)
 
void SetMetadataAsUserID (const clang::Type *type, lldb::user_id_t user_id)
 
void SetMetadata (const clang::Decl *object, ClangASTMetadata &meta_data)
 
void SetMetadata (const clang::Type *object, ClangASTMetadata &meta_data)
 
ClangASTMetadataGetMetadata (const clang::Decl *object)
 
ClangASTMetadataGetMetadata (const clang::Type *object)
 
void SetCXXRecordDeclAccess (const clang::CXXRecordDecl *object, clang::AccessSpecifier access)
 
clang::AccessSpecifier GetCXXRecordDeclAccess (const clang::CXXRecordDecl *object)
 
CompilerType GetBuiltinTypeForEncodingAndBitSize (lldb::Encoding encoding, size_t bit_size) override
 
CompilerType GetBasicType (lldb::BasicType type)
 
CompilerType GetBuiltinTypeForDWARFEncodingAndBitSize (llvm::StringRef type_name, uint32_t dw_ate, uint32_t bit_size)
 
CompilerType GetCStringType (bool is_const)
 
CompilerDeclContext GetCompilerDeclContextForType (const CompilerType &type) override
 Returns the direct parent context of specified type.
 
uint32_t GetPointerByteSize () override
 
clang::TranslationUnitDecl * GetTranslationUnitDecl ()
 
CompilerType GetType (clang::QualType qt)
 Creates a CompilerType from the given QualType with the current TypeSystemClang instance as the CompilerType's typesystem.
 
CompilerType GetTypeForDecl (clang::NamedDecl *decl)
 
CompilerType GetTypeForDecl (clang::TagDecl *decl)
 
CompilerType GetTypeForDecl (clang::ObjCInterfaceDecl *objc_decl)
 
CompilerType GetTypeForDecl (clang::ValueDecl *value_decl)
 
template<typename RecordDeclType >
CompilerType GetTypeForIdentifier (llvm::StringRef type_name, clang::DeclContext *decl_context=nullptr)
 
CompilerType CreateStructForIdentifier (llvm::StringRef type_name, const std::initializer_list< std::pair< const char *, CompilerType > > &type_fields, bool packed=false)
 
CompilerType GetOrCreateStructForIdentifier (llvm::StringRef type_name, const std::initializer_list< std::pair< const char *, CompilerType > > &type_fields, bool packed=false)
 
uint32_t GetNumBaseClasses (const clang::CXXRecordDecl *cxx_record_decl, bool omit_empty_base_classes)
 
uint32_t GetIndexForRecordChild (const clang::RecordDecl *record_decl, clang::NamedDecl *canonical_decl, bool omit_empty_base_classes)
 
uint32_t GetIndexForRecordBase (const clang::RecordDecl *record_decl, const clang::CXXBaseSpecifier *base_spec, bool omit_empty_base_classes)
 
OptionalClangModuleID GetOrCreateClangModule (llvm::StringRef name, OptionalClangModuleID parent, bool is_framework=false, bool is_explicit=false)
 Synthesize a clang::Module and return its ID or a default-constructed ID.
 
CompilerType CreateRecordType (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, lldb::AccessType access_type, llvm::StringRef name, int kind, lldb::LanguageType language, ClangASTMetadata *metadata=nullptr, bool exports_symbols=false)
 
clang::FunctionTemplateDecl * CreateFunctionTemplateDecl (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, clang::FunctionDecl *func_decl, const TemplateParameterInfos &infos)
 
void CreateFunctionTemplateSpecializationInfo (clang::FunctionDecl *func_decl, clang::FunctionTemplateDecl *Template, const TemplateParameterInfos &infos)
 
clang::ClassTemplateDecl * CreateClassTemplateDecl (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, lldb::AccessType access_type, llvm::StringRef class_name, int kind, const TemplateParameterInfos &infos)
 
clang::TemplateTemplateParmDecl * CreateTemplateTemplateParmDecl (const char *template_name)
 
clang::ClassTemplateSpecializationDecl * CreateClassTemplateSpecializationDecl (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, clang::ClassTemplateDecl *class_template_decl, int kind, const TemplateParameterInfos &infos)
 
CompilerType CreateClassTemplateSpecializationType (clang::ClassTemplateSpecializationDecl *class_template_specialization_decl)
 
bool FieldIsBitfield (clang::FieldDecl *field, uint32_t &bitfield_bit_size)
 
bool RecordHasFields (const clang::RecordDecl *record_decl)
 
bool BaseSpecifierIsEmpty (const clang::CXXBaseSpecifier *b)
 
CompilerType CreateObjCClass (llvm::StringRef name, clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, bool isForwardDecl, bool isInternal, ClangASTMetadata *metadata=nullptr)
 
clang::NamespaceDecl * GetUniqueNamespaceDeclaration (const char *name, clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, bool is_inline=false)
 
clang::FunctionDecl * CreateFunctionDeclaration (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, llvm::StringRef name, const CompilerType &function_Type, clang::StorageClass storage, bool is_inline)
 
CompilerType CreateFunctionType (const CompilerType &result_type, const CompilerType *args, unsigned num_args, bool is_variadic, unsigned type_quals, clang::CallingConv cc=clang::CC_C, clang::RefQualifierKind ref_qual=clang::RQ_None)
 
clang::ParmVarDecl * CreateParameterDeclaration (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, const char *name, const CompilerType &param_type, int storage, bool add_decl=false)
 
void SetFunctionParameters (clang::FunctionDecl *function_decl, llvm::ArrayRef< clang::ParmVarDecl * > params)
 
CompilerType CreateBlockPointerType (const CompilerType &function_type)
 
CompilerType CreateArrayType (const CompilerType &element_type, size_t element_count, bool is_vector)
 
CompilerType CreateEnumerationType (llvm::StringRef name, clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, const Declaration &decl, const CompilerType &integer_qual_type, bool is_scoped)
 
CompilerType GetIntTypeFromBitSize (size_t bit_size, bool is_signed)
 
CompilerType GetPointerSizedIntType (bool is_signed)
 
plugin::dwarf::DWARFASTParserGetDWARFParser () override
 
PDBASTParserGetPDBParser () override
 
npdb::PdbAstBuilderGetNativePDBParser () override
 
void CompleteTagDecl (clang::TagDecl *)
 
void CompleteObjCInterfaceDecl (clang::ObjCInterfaceDecl *)
 
bool LayoutRecordType (const clang::RecordDecl *record_decl, uint64_t &size, uint64_t &alignment, llvm::DenseMap< const clang::FieldDecl *, uint64_t > &field_offsets, llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &base_offsets, llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &vbase_offsets)
 
CompilerDecl GetCompilerDecl (clang::Decl *decl)
 Creates a CompilerDecl from the given Decl with the current TypeSystemClang instance as its typesystem.
 
ConstString DeclGetName (void *opaque_decl) override
 
ConstString DeclGetMangledName (void *opaque_decl) override
 
CompilerDeclContext DeclGetDeclContext (void *opaque_decl) override
 
CompilerType DeclGetFunctionReturnType (void *opaque_decl) override
 
size_t DeclGetFunctionNumArguments (void *opaque_decl) override
 
CompilerType DeclGetFunctionArgumentType (void *opaque_decl, size_t arg_idx) override
 
std::vector< lldb_private::CompilerContextDeclGetCompilerContext (void *opaque_decl) override
 
Scalar DeclGetConstantValue (void *opaque_decl) override
 
CompilerType GetTypeForDecl (void *opaque_decl) override
 
CompilerDeclContext CreateDeclContext (clang::DeclContext *ctx)
 Creates a CompilerDeclContext from the given DeclContext with the current TypeSystemClang instance as its typesystem.
 
std::vector< CompilerDeclDeclContextFindDeclByName (void *opaque_decl_ctx, ConstString name, const bool ignore_using_decls) override
 
ConstString DeclContextGetName (void *opaque_decl_ctx) override
 
ConstString DeclContextGetScopeQualifiedName (void *opaque_decl_ctx) override
 
bool DeclContextIsClassMethod (void *opaque_decl_ctx) override
 
bool DeclContextIsContainedInLookup (void *opaque_decl_ctx, void *other_opaque_decl_ctx) override
 
lldb::LanguageType DeclContextGetLanguage (void *opaque_decl_ctx) override
 
std::vector< lldb_private::CompilerContextDeclContextGetCompilerContext (void *opaque_decl_ctx) override
 
bool Verify (lldb::opaque_compiler_type_t type) override
 Verify the integrity of the type to catch CompilerTypes that mix and match invalid TypeSystem/Opaque type pairs.
 
bool IsArrayType (lldb::opaque_compiler_type_t type, CompilerType *element_type, uint64_t *size, bool *is_incomplete) override
 
bool IsVectorType (lldb::opaque_compiler_type_t type, CompilerType *element_type, uint64_t *size) override
 
bool IsAggregateType (lldb::opaque_compiler_type_t type) override
 
bool IsAnonymousType (lldb::opaque_compiler_type_t type) override
 
bool IsBeingDefined (lldb::opaque_compiler_type_t type) override
 
bool IsCharType (lldb::opaque_compiler_type_t type) override
 
bool IsCompleteType (lldb::opaque_compiler_type_t type) override
 
bool IsConst (lldb::opaque_compiler_type_t type) override
 
bool IsCStringType (lldb::opaque_compiler_type_t type, uint32_t &length)
 
bool IsDefined (lldb::opaque_compiler_type_t type) override
 
bool IsFloatingPointType (lldb::opaque_compiler_type_t type, uint32_t &count, bool &is_complex) override
 
bool IsFunctionType (lldb::opaque_compiler_type_t type) override
 
uint32_t IsHomogeneousAggregate (lldb::opaque_compiler_type_t type, CompilerType *base_type_ptr) override
 
size_t GetNumberOfFunctionArguments (lldb::opaque_compiler_type_t type) override
 
CompilerType GetFunctionArgumentAtIndex (lldb::opaque_compiler_type_t type, const size_t index) override
 
bool IsFunctionPointerType (lldb::opaque_compiler_type_t type) override
 
bool IsMemberFunctionPointerType (lldb::opaque_compiler_type_t type) override
 
bool IsBlockPointerType (lldb::opaque_compiler_type_t type, CompilerType *function_pointer_type_ptr) override
 
bool IsIntegerType (lldb::opaque_compiler_type_t type, bool &is_signed) override
 
bool IsEnumerationType (lldb::opaque_compiler_type_t type, bool &is_signed) override
 
bool IsScopedEnumerationType (lldb::opaque_compiler_type_t type) override
 
bool IsPolymorphicClass (lldb::opaque_compiler_type_t type) override
 
bool IsPossibleDynamicType (lldb::opaque_compiler_type_t type, CompilerType *target_type, bool check_cplusplus, bool check_objc) override
 
bool IsRuntimeGeneratedType (lldb::opaque_compiler_type_t type) override
 This is used by swift.
 
bool IsPointerType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type) override
 
bool IsPointerOrReferenceType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type) override
 
bool IsReferenceType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type, bool *is_rvalue) override
 
bool IsScalarType (lldb::opaque_compiler_type_t type) override
 
bool IsTypedefType (lldb::opaque_compiler_type_t type) override
 
bool IsVoidType (lldb::opaque_compiler_type_t type) override
 
bool CanPassInRegisters (const CompilerType &type) override
 
bool SupportsLanguage (lldb::LanguageType language) override
 
bool GetCompleteType (lldb::opaque_compiler_type_t type) override
 
bool IsForcefullyCompleted (lldb::opaque_compiler_type_t type) override
 
ConstString GetTypeName (lldb::opaque_compiler_type_t type, bool base_only) override
 
ConstString GetDisplayTypeName (lldb::opaque_compiler_type_t type) override
 
uint32_t GetTypeInfo (lldb::opaque_compiler_type_t type, CompilerType *pointee_or_element_compiler_type) override
 
lldb::LanguageType GetMinimumLanguage (lldb::opaque_compiler_type_t type) override
 
lldb::TypeClass GetTypeClass (lldb::opaque_compiler_type_t type) override
 
unsigned GetTypeQualifiers (lldb::opaque_compiler_type_t type) override
 
CompilerType GetArrayElementType (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope) override
 
CompilerType GetArrayType (lldb::opaque_compiler_type_t type, uint64_t size) override
 
CompilerType GetCanonicalType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetFullyUnqualifiedType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetEnumerationIntegerType (lldb::opaque_compiler_type_t type) override
 
int GetFunctionArgumentCount (lldb::opaque_compiler_type_t type) override
 
CompilerType GetFunctionArgumentTypeAtIndex (lldb::opaque_compiler_type_t type, size_t idx) override
 
CompilerType GetFunctionReturnType (lldb::opaque_compiler_type_t type) override
 
size_t GetNumMemberFunctions (lldb::opaque_compiler_type_t type) override
 
TypeMemberFunctionImpl GetMemberFunctionAtIndex (lldb::opaque_compiler_type_t type, size_t idx) override
 
CompilerType GetNonReferenceType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetPointeeType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetPointerType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetLValueReferenceType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetRValueReferenceType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetAtomicType (lldb::opaque_compiler_type_t type) override
 
CompilerType AddConstModifier (lldb::opaque_compiler_type_t type) override
 
CompilerType AddVolatileModifier (lldb::opaque_compiler_type_t type) override
 
CompilerType AddRestrictModifier (lldb::opaque_compiler_type_t type) override
 
CompilerType CreateTypedef (lldb::opaque_compiler_type_t type, const char *name, const CompilerDeclContext &decl_ctx, uint32_t opaque_payload) override
 Using the current type, create a new typedef to that type using "typedef_name" as the name and "decl_ctx" as the decl context.
 
CompilerType GetTypedefedType (lldb::opaque_compiler_type_t type) override
 
CompilerType GetBasicTypeFromAST (lldb::BasicType basic_type) override
 
CompilerType CreateGenericFunctionPrototype () override
 
const llvm::fltSemantics & GetFloatTypeSemantics (size_t byte_size) override
 
std::optional< uint64_t > GetByteSize (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope)
 
std::optional< uint64_t > GetBitSize (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope) override
 
lldb::Encoding GetEncoding (lldb::opaque_compiler_type_t type, uint64_t &count) override
 
lldb::Format GetFormat (lldb::opaque_compiler_type_t type) override
 
std::optional< size_t > GetTypeBitAlign (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope) override
 
llvm::Expected< uint32_t > GetNumChildren (lldb::opaque_compiler_type_t type, bool omit_empty_base_classes, const ExecutionContext *exe_ctx) override
 
CompilerType GetBuiltinTypeByName (ConstString name) override
 
lldb::BasicType GetBasicTypeEnumeration (lldb::opaque_compiler_type_t type) override
 
void ForEachEnumerator (lldb::opaque_compiler_type_t type, std::function< bool(const CompilerType &integer_type, ConstString name, const llvm::APSInt &value)> const &callback) override
 
uint32_t GetNumFields (lldb::opaque_compiler_type_t type) override
 
CompilerType GetFieldAtIndex (lldb::opaque_compiler_type_t type, size_t idx, std::string &name, uint64_t *bit_offset_ptr, uint32_t *bitfield_bit_size_ptr, bool *is_bitfield_ptr) override
 
uint32_t GetNumDirectBaseClasses (lldb::opaque_compiler_type_t type) override
 
uint32_t GetNumVirtualBaseClasses (lldb::opaque_compiler_type_t type) override
 
CompilerType GetDirectBaseClassAtIndex (lldb::opaque_compiler_type_t type, size_t idx, uint32_t *bit_offset_ptr) override
 
CompilerType GetVirtualBaseClassAtIndex (lldb::opaque_compiler_type_t type, size_t idx, uint32_t *bit_offset_ptr) override
 
CompilerDecl GetStaticFieldWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name) override
 
CompilerType GetChildCompilerTypeAtIndex (lldb::opaque_compiler_type_t type, ExecutionContext *exe_ctx, size_t idx, bool transparent_pointers, bool omit_empty_base_classes, bool ignore_array_bounds, std::string &child_name, uint32_t &child_byte_size, int32_t &child_byte_offset, uint32_t &child_bitfield_bit_size, uint32_t &child_bitfield_bit_offset, bool &child_is_base_class, bool &child_is_deref_of_parent, ValueObject *valobj, uint64_t &language_flags) override
 
uint32_t GetIndexOfChildWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name, bool omit_empty_base_classes) override
 
size_t GetIndexOfChildMemberWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name, bool omit_empty_base_classes, std::vector< uint32_t > &child_indexes) override
 
CompilerType GetDirectNestedTypeWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name) override
 
bool IsTemplateType (lldb::opaque_compiler_type_t type) override
 
size_t GetNumTemplateArguments (lldb::opaque_compiler_type_t type, bool expand_pack) override
 
lldb::TemplateArgumentKind GetTemplateArgumentKind (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack) override
 
CompilerType GetTypeTemplateArgument (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack) override
 
std::optional< CompilerType::IntegralTemplateArgumentGetIntegralTemplateArgument (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack) override
 
CompilerType GetTypeForFormatters (void *type) override
 
uint32_t CountDeclLevels (clang::DeclContext *frame_decl_ctx, clang::DeclContext *child_decl_ctx, ConstString *child_name=nullptr, CompilerType *child_type=nullptr)
 
clang::CXXMethodDecl * AddMethodToCXXRecordType (lldb::opaque_compiler_type_t type, llvm::StringRef name, const char *mangled_name, const CompilerType &method_type, lldb::AccessType access, bool is_virtual, bool is_static, bool is_inline, bool is_explicit, bool is_attr_used, bool is_artificial)
 
void AddMethodOverridesForCXXRecordType (lldb::opaque_compiler_type_t type)
 
std::unique_ptr< clang::CXXBaseSpecifier > CreateBaseClassSpecifier (lldb::opaque_compiler_type_t type, lldb::AccessType access, bool is_virtual, bool base_of_class)
 
bool TransferBaseClasses (lldb::opaque_compiler_type_t type, std::vector< std::unique_ptr< clang::CXXBaseSpecifier > > bases)
 
clang::EnumConstantDecl * AddEnumerationValueToEnumerationType (const CompilerType &enum_type, const Declaration &decl, const char *name, int64_t enum_value, uint32_t enum_value_bit_size)
 
clang::EnumConstantDecl * AddEnumerationValueToEnumerationType (const CompilerType &enum_type, const Declaration &decl, const char *name, const llvm::APSInt &value)
 
CompilerType GetEnumerationIntegerType (CompilerType type)
 Returns the underlying integer type for an enum type.
 
LLVM_DUMP_METHOD void dump (lldb::opaque_compiler_type_t type) const override
 Convenience LLVM-style dump method for use in the debugger only.
 
void Dump (llvm::raw_ostream &output) override
 
void DumpFromSymbolFile (Stream &s, llvm::StringRef symbol_name)
 Dump clang AST types from the symbol file.
 
bool DumpTypeValue (lldb::opaque_compiler_type_t type, Stream &s, lldb::Format format, const DataExtractor &data, lldb::offset_t data_offset, size_t data_byte_size, uint32_t bitfield_bit_size, uint32_t bitfield_bit_offset, ExecutionContextScope *exe_scope) override
 
void DumpTypeDescription (lldb::opaque_compiler_type_t type, lldb::DescriptionLevel level=lldb::eDescriptionLevelFull) override
 Dump the type to stdout.
 
void DumpTypeDescription (lldb::opaque_compiler_type_t type, Stream &s, lldb::DescriptionLevel level=lldb::eDescriptionLevelFull) override
 Print a description of the type to a stream.
 
clang::ClassTemplateDecl * ParseClassTemplateDecl (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, lldb::AccessType access_type, const char *parent_name, int tag_decl_kind, const TypeSystemClang::TemplateParameterInfos &template_param_infos)
 
clang::BlockDecl * CreateBlockDeclaration (clang::DeclContext *ctx, OptionalClangModuleID owning_module)
 
clang::UsingDirectiveDecl * CreateUsingDirectiveDeclaration (clang::DeclContext *decl_ctx, OptionalClangModuleID owning_module, clang::NamespaceDecl *ns_decl)
 
clang::UsingDecl * CreateUsingDeclaration (clang::DeclContext *current_decl_ctx, OptionalClangModuleID owning_module, clang::NamedDecl *target)
 
clang::VarDecl * CreateVariableDeclaration (clang::DeclContext *decl_context, OptionalClangModuleID owning_module, const char *name, clang::QualType type)
 
clang::DeclarationName GetDeclarationName (llvm::StringRef name, const CompilerType &function_clang_type)
 
clang::LangOptions * GetLangOpts () const
 
clang::SourceManager * GetSourceMgr () const
 
bool SetDeclIsForcefullyCompleted (const clang::TagDecl *td)
 
std::string PrintTemplateParams (const TemplateParameterInfos &template_param_infos)
 Return the template parameters (including surrounding <>) in string form.
 
- Public Member Functions inherited from lldb_private::TypeSystem
 TypeSystem ()
 
 ~TypeSystem () override
 
virtual bool isA (const void *ClassID) const =0
 
virtual void Finalize ()
 Free up any resources associated with this TypeSystem.
 
virtual plugin::dwarf::DWARFASTParserGetDWARFParser ()
 
virtual PDBASTParserGetPDBParser ()
 
virtual npdb::PdbAstBuilderGetNativePDBParser ()
 
virtual SymbolFileGetSymbolFile () const
 
virtual void SetSymbolFile (SymbolFile *sym_file)
 
virtual ConstString DeclGetName (void *opaque_decl)=0
 
virtual ConstString DeclGetMangledName (void *opaque_decl)
 
virtual CompilerDeclContext DeclGetDeclContext (void *opaque_decl)
 
virtual CompilerType DeclGetFunctionReturnType (void *opaque_decl)
 
virtual size_t DeclGetFunctionNumArguments (void *opaque_decl)
 
virtual CompilerType DeclGetFunctionArgumentType (void *opaque_decl, size_t arg_idx)
 
virtual std::vector< lldb_private::CompilerContextDeclGetCompilerContext (void *opaque_decl)
 
virtual Scalar DeclGetConstantValue (void *opaque_decl)
 
virtual CompilerType GetTypeForDecl (void *opaque_decl)=0
 
virtual std::vector< CompilerDeclDeclContextFindDeclByName (void *opaque_decl_ctx, ConstString name, const bool ignore_imported_decls)
 
virtual ConstString DeclContextGetName (void *opaque_decl_ctx)=0
 
virtual ConstString DeclContextGetScopeQualifiedName (void *opaque_decl_ctx)=0
 
virtual bool DeclContextIsClassMethod (void *opaque_decl_ctx)=0
 
virtual bool DeclContextIsContainedInLookup (void *opaque_decl_ctx, void *other_opaque_decl_ctx)=0
 
virtual lldb::LanguageType DeclContextGetLanguage (void *opaque_decl_ctx)=0
 
virtual CompilerDeclContext GetCompilerDeclContextForType (const CompilerType &type)
 Returns the direct parent context of specified type.
 
virtual std::vector< lldb_private::CompilerContextDeclContextGetCompilerContext (void *opaque_decl_ctx)
 
virtual bool Verify (lldb::opaque_compiler_type_t type)=0
 Verify the integrity of the type to catch CompilerTypes that mix and match invalid TypeSystem/Opaque type pairs.
 
virtual bool IsArrayType (lldb::opaque_compiler_type_t type, CompilerType *element_type, uint64_t *size, bool *is_incomplete)=0
 
virtual bool IsAggregateType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsAnonymousType (lldb::opaque_compiler_type_t type)
 
virtual bool IsCharType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsCompleteType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsDefined (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsFloatingPointType (lldb::opaque_compiler_type_t type, uint32_t &count, bool &is_complex)=0
 
virtual bool IsFunctionType (lldb::opaque_compiler_type_t type)=0
 
virtual size_t GetNumberOfFunctionArguments (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetFunctionArgumentAtIndex (lldb::opaque_compiler_type_t type, const size_t index)=0
 
virtual bool IsFunctionPointerType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsMemberFunctionPointerType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsBlockPointerType (lldb::opaque_compiler_type_t type, CompilerType *function_pointer_type_ptr)=0
 
virtual bool IsIntegerType (lldb::opaque_compiler_type_t type, bool &is_signed)=0
 
virtual bool IsEnumerationType (lldb::opaque_compiler_type_t type, bool &is_signed)
 
virtual bool IsScopedEnumerationType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsPossibleDynamicType (lldb::opaque_compiler_type_t type, CompilerType *target_type, bool check_cplusplus, bool check_objc)=0
 
virtual bool IsPointerType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type)=0
 
virtual bool IsScalarType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsVoidType (lldb::opaque_compiler_type_t type)=0
 
virtual bool CanPassInRegisters (const CompilerType &type)=0
 
virtual bool SupportsLanguage (lldb::LanguageType language)=0
 
virtual bool GetCompleteType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsForcefullyCompleted (lldb::opaque_compiler_type_t type)
 
virtual uint32_t GetPointerByteSize ()=0
 
virtual ConstString GetTypeName (lldb::opaque_compiler_type_t type, bool BaseOnly)=0
 
virtual ConstString GetDisplayTypeName (lldb::opaque_compiler_type_t type)=0
 
virtual uint32_t GetTypeInfo (lldb::opaque_compiler_type_t type, CompilerType *pointee_or_element_compiler_type)=0
 
virtual lldb::LanguageType GetMinimumLanguage (lldb::opaque_compiler_type_t type)=0
 
virtual lldb::TypeClass GetTypeClass (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetArrayElementType (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope)=0
 
virtual CompilerType GetArrayType (lldb::opaque_compiler_type_t type, uint64_t size)
 
virtual CompilerType GetCanonicalType (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetEnumerationIntegerType (lldb::opaque_compiler_type_t type)=0
 
virtual int GetFunctionArgumentCount (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetFunctionArgumentTypeAtIndex (lldb::opaque_compiler_type_t type, size_t idx)=0
 
virtual CompilerType GetFunctionReturnType (lldb::opaque_compiler_type_t type)=0
 
virtual size_t GetNumMemberFunctions (lldb::opaque_compiler_type_t type)=0
 
virtual TypeMemberFunctionImpl GetMemberFunctionAtIndex (lldb::opaque_compiler_type_t type, size_t idx)=0
 
virtual CompilerType GetPointeeType (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetPointerType (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetLValueReferenceType (lldb::opaque_compiler_type_t type)
 
virtual CompilerType GetRValueReferenceType (lldb::opaque_compiler_type_t type)
 
virtual CompilerType GetAtomicType (lldb::opaque_compiler_type_t type)
 
virtual CompilerType AddConstModifier (lldb::opaque_compiler_type_t type)
 
virtual CompilerType AddVolatileModifier (lldb::opaque_compiler_type_t type)
 
virtual CompilerType AddRestrictModifier (lldb::opaque_compiler_type_t type)
 
virtual CompilerType CreateTypedef (lldb::opaque_compiler_type_t type, const char *name, const CompilerDeclContext &decl_ctx, uint32_t opaque_payload)
 
virtual const llvm::fltSemantics & GetFloatTypeSemantics (size_t byte_size)=0
 
virtual std::optional< uint64_t > GetBitSize (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope)=0
 
virtual lldb::Encoding GetEncoding (lldb::opaque_compiler_type_t type, uint64_t &count)=0
 
virtual lldb::Format GetFormat (lldb::opaque_compiler_type_t type)=0
 
virtual llvm::Expected< uint32_t > GetNumChildren (lldb::opaque_compiler_type_t type, bool omit_empty_base_classes, const ExecutionContext *exe_ctx)=0
 
virtual CompilerType GetBuiltinTypeByName (ConstString name)
 
virtual lldb::BasicType GetBasicTypeEnumeration (lldb::opaque_compiler_type_t type)=0
 
virtual void ForEachEnumerator (lldb::opaque_compiler_type_t type, std::function< bool(const CompilerType &integer_type, ConstString name, const llvm::APSInt &value)> const &callback)
 
virtual uint32_t GetNumFields (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetFieldAtIndex (lldb::opaque_compiler_type_t type, size_t idx, std::string &name, uint64_t *bit_offset_ptr, uint32_t *bitfield_bit_size_ptr, bool *is_bitfield_ptr)=0
 
virtual uint32_t GetNumDirectBaseClasses (lldb::opaque_compiler_type_t type)=0
 
virtual uint32_t GetNumVirtualBaseClasses (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetDirectBaseClassAtIndex (lldb::opaque_compiler_type_t type, size_t idx, uint32_t *bit_offset_ptr)=0
 
virtual CompilerType GetVirtualBaseClassAtIndex (lldb::opaque_compiler_type_t type, size_t idx, uint32_t *bit_offset_ptr)=0
 
virtual CompilerDecl GetStaticFieldWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name)
 
virtual CompilerType GetChildCompilerTypeAtIndex (lldb::opaque_compiler_type_t type, ExecutionContext *exe_ctx, size_t idx, bool transparent_pointers, bool omit_empty_base_classes, bool ignore_array_bounds, std::string &child_name, uint32_t &child_byte_size, int32_t &child_byte_offset, uint32_t &child_bitfield_bit_size, uint32_t &child_bitfield_bit_offset, bool &child_is_base_class, bool &child_is_deref_of_parent, ValueObject *valobj, uint64_t &language_flags)=0
 
virtual uint32_t GetIndexOfChildWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name, bool omit_empty_base_classes)=0
 
virtual size_t GetIndexOfChildMemberWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name, bool omit_empty_base_classes, std::vector< uint32_t > &child_indexes)=0
 
virtual CompilerType GetDirectNestedTypeWithName (lldb::opaque_compiler_type_t type, llvm::StringRef name)
 
virtual bool IsTemplateType (lldb::opaque_compiler_type_t type)
 
virtual size_t GetNumTemplateArguments (lldb::opaque_compiler_type_t type, bool expand_pack)
 
virtual lldb::TemplateArgumentKind GetTemplateArgumentKind (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack)
 
virtual CompilerType GetTypeTemplateArgument (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack)
 
virtual std::optional< CompilerType::IntegralTemplateArgumentGetIntegralTemplateArgument (lldb::opaque_compiler_type_t type, size_t idx, bool expand_pack)
 
virtual LLVM_DUMP_METHOD void dump (lldb::opaque_compiler_type_t type) const =0
 Convenience LLVM-style dump method for use in the debugger only.
 
virtual bool DumpTypeValue (lldb::opaque_compiler_type_t type, Stream &s, lldb::Format format, const DataExtractor &data, lldb::offset_t data_offset, size_t data_byte_size, uint32_t bitfield_bit_size, uint32_t bitfield_bit_offset, ExecutionContextScope *exe_scope)=0
 
virtual void DumpTypeDescription (lldb::opaque_compiler_type_t type, lldb::DescriptionLevel level=lldb::eDescriptionLevelFull)=0
 Dump the type to stdout.
 
virtual void DumpTypeDescription (lldb::opaque_compiler_type_t type, Stream &s, lldb::DescriptionLevel level=lldb::eDescriptionLevelFull)=0
 Print a description of the type to a stream.
 
virtual void Dump (llvm::raw_ostream &output)=0
 Dump a textual representation of the internal TypeSystem state to the given stream.
 
virtual bool IsRuntimeGeneratedType (lldb::opaque_compiler_type_t type)=0
 This is used by swift.
 
virtual bool IsPointerOrReferenceType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type)=0
 
virtual unsigned GetTypeQualifiers (lldb::opaque_compiler_type_t type)=0
 
virtual std::optional< size_t > GetTypeBitAlign (lldb::opaque_compiler_type_t type, ExecutionContextScope *exe_scope)=0
 
virtual CompilerType GetBasicTypeFromAST (lldb::BasicType basic_type)=0
 
virtual CompilerType CreateGenericFunctionPrototype ()
 
virtual CompilerType GetBuiltinTypeForEncodingAndBitSize (lldb::Encoding encoding, size_t bit_size)=0
 
virtual bool IsBeingDefined (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsConst (lldb::opaque_compiler_type_t type)=0
 
virtual uint32_t IsHomogeneousAggregate (lldb::opaque_compiler_type_t type, CompilerType *base_type_ptr)=0
 
virtual bool IsPolymorphicClass (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsTypedefType (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetTypedefedType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsVectorType (lldb::opaque_compiler_type_t type, CompilerType *element_type, uint64_t *size)=0
 
virtual CompilerType GetFullyUnqualifiedType (lldb::opaque_compiler_type_t type)=0
 
virtual CompilerType GetNonReferenceType (lldb::opaque_compiler_type_t type)=0
 
virtual bool IsReferenceType (lldb::opaque_compiler_type_t type, CompilerType *pointee_type, bool *is_rvalue)=0
 
virtual bool ShouldTreatScalarValueAsAddress (lldb::opaque_compiler_type_t type)
 
virtual UserExpressionGetUserExpression (llvm::StringRef expr, llvm::StringRef prefix, lldb::LanguageType language, Expression::ResultType desired_type, const EvaluateExpressionOptions &options, ValueObject *ctx_obj)
 
virtual FunctionCallerGetFunctionCaller (const CompilerType &return_type, const Address &function_address, const ValueList &arg_value_list, const char *name)
 
virtual std::unique_ptr< UtilityFunctionCreateUtilityFunction (std::string text, std::string name)
 
virtual PersistentExpressionStateGetPersistentExpressionState ()
 
virtual CompilerType GetTypeForFormatters (void *type)
 
virtual LazyBool ShouldPrintAsOneLiner (void *type, ValueObject *valobj)
 
virtual bool IsMeaninglessWithoutDynamicResolution (void *type)
 
virtual std::optional< llvm::json::Value > ReportStatistics ()
 
bool GetHasForcefullyCompletedTypes () const
 
- Public Member Functions inherited from lldb_private::PluginInterface
 PluginInterface ()=default
 
virtual ~PluginInterface ()=default
 
virtual llvm::StringRef GetPluginName ()=0
 
 PluginInterface (const PluginInterface &)=delete
 
PluginInterfaceoperator= (const PluginInterface &)=delete
 

Static Public Member Functions

static bool classof (const TypeSystem *ts)
 
static llvm::StringRef GetPluginNameStatic ()
 
static lldb::TypeSystemSP CreateInstance (lldb::LanguageType language, Module *module, Target *target)
 
static LanguageSet GetSupportedLanguagesForTypes ()
 
static LanguageSet GetSupportedLanguagesForExpressions ()
 
static void Initialize ()
 
static void Terminate ()
 
static TypeSystemClangGetASTContext (clang::ASTContext *ast_ctx)
 
static void DumpDeclHiearchy (clang::Decl *decl)
 
static void DumpDeclContextHiearchy (clang::DeclContext *decl_ctx)
 
static bool GetCompleteDecl (clang::ASTContext *ast, clang::Decl *decl)
 
static lldb::BasicType GetBasicTypeEnumeration (llvm::StringRef name)
 
static clang::DeclContext * GetDeclContextForType (clang::QualType type)
 
static clang::DeclContext * GetDeclContextForType (const CompilerType &type)
 
static bool AreTypesSame (CompilerType type1, CompilerType type2, bool ignore_qualifiers=false)
 
static bool IsOperator (llvm::StringRef name, clang::OverloadedOperatorKind &op_kind)
 
static clang::AccessSpecifier ConvertAccessTypeToAccessSpecifier (lldb::AccessType access)
 
static clang::AccessSpecifier UnifyAccessSpecifiers (clang::AccessSpecifier lhs, clang::AccessSpecifier rhs)
 
static clang::DeclContext * GetAsDeclContext (clang::FunctionDecl *function_decl)
 
static bool CheckOverloadedOperatorKindParameterCount (bool is_method, clang::OverloadedOperatorKind op_kind, uint32_t num_params)
 
static CompilerType GetFloatTypeFromBitSize (clang::ASTContext *ast, size_t bit_size)
 
static void SetOwningModule (clang::Decl *decl, OptionalClangModuleID owning_module)
 Set the owning module for decl.
 
static clang::DeclContext * DeclContextGetAsDeclContext (const CompilerDeclContext &dc)
 
static clang::ObjCMethodDecl * DeclContextGetAsObjCMethodDecl (const CompilerDeclContext &dc)
 
static clang::CXXMethodDecl * DeclContextGetAsCXXMethodDecl (const CompilerDeclContext &dc)
 
static clang::FunctionDecl * DeclContextGetAsFunctionDecl (const CompilerDeclContext &dc)
 
static clang::NamespaceDecl * DeclContextGetAsNamespaceDecl (const CompilerDeclContext &dc)
 
static ClangASTMetadataDeclContextGetMetaData (const CompilerDeclContext &dc, const clang::Decl *object)
 
static clang::ASTContext * DeclContextGetTypeSystemClang (const CompilerDeclContext &dc)
 
static bool IsCXXClassType (const CompilerType &type)
 
static bool IsObjCClassType (const CompilerType &type)
 
static bool IsObjCClassTypeAndHasIVars (const CompilerType &type, bool check_superclass)
 
static bool IsObjCObjectOrInterfaceType (const CompilerType &type)
 
static bool IsObjCObjectPointerType (const CompilerType &type, CompilerType *target_type=nullptr)
 
static bool IsClassType (lldb::opaque_compiler_type_t type)
 
static bool IsEnumType (lldb::opaque_compiler_type_t type)
 
static std::optional< std::string > GetCXXClassName (const CompilerType &type)
 
static uint32_t GetNumPointeeChildren (clang::QualType type)
 
static clang::FieldDecl * AddFieldToRecordType (const CompilerType &type, llvm::StringRef name, const CompilerType &field_type, lldb::AccessType access, uint32_t bitfield_bit_size)
 
static void BuildIndirectFields (const CompilerType &type)
 
static void SetIsPacked (const CompilerType &type)
 
static clang::VarDecl * AddVariableToRecordType (const CompilerType &type, llvm::StringRef name, const CompilerType &var_type, lldb::AccessType access)
 
static void SetIntegerInitializerForVariable (clang::VarDecl *var, const llvm::APInt &init_value)
 Initializes a variable with an integer value.
 
static void SetFloatingInitializerForVariable (clang::VarDecl *var, const llvm::APFloat &init_value)
 Initializes a variable with a floating point value.
 
static bool SetObjCSuperClass (const CompilerType &type, const CompilerType &superclass_compiler_type)
 
static bool AddObjCClassProperty (const CompilerType &type, const char *property_name, const CompilerType &property_compiler_type, clang::ObjCIvarDecl *ivar_decl, const char *property_setter_name, const char *property_getter_name, uint32_t property_attributes, ClangASTMetadata *metadata)
 
static clang::ObjCMethodDecl * AddMethodToObjCObjectType (const CompilerType &type, const char *name, const CompilerType &method_compiler_type, bool is_artificial, bool is_variadic, bool is_objc_direct_call)
 
static bool SetHasExternalStorage (lldb::opaque_compiler_type_t type, bool has_extern)
 
static bool StartTagDeclarationDefinition (const CompilerType &type)
 
static bool CompleteTagDeclarationDefinition (const CompilerType &type)
 
static CompilerType CreateMemberPointerType (const CompilerType &type, const CompilerType &pointee_type)
 
static void DumpTypeName (const CompilerType &type)
 
static clang::EnumDecl * GetAsEnumDecl (const CompilerType &type)
 
static clang::RecordDecl * GetAsRecordDecl (const CompilerType &type)
 
static clang::TagDecl * GetAsTagDecl (const CompilerType &type)
 
static clang::TypedefNameDecl * GetAsTypedefDecl (const CompilerType &type)
 
static clang::CXXRecordDecl * GetAsCXXRecordDecl (lldb::opaque_compiler_type_t type)
 
static clang::ObjCInterfaceDecl * GetAsObjCInterfaceDecl (const CompilerType &type)
 
static lldb::opaque_compiler_type_t GetOpaqueCompilerType (clang::ASTContext *ast, lldb::BasicType basic_type)
 
static clang::QualType GetQualType (lldb::opaque_compiler_type_t type)
 
static clang::QualType GetCanonicalQualType (lldb::opaque_compiler_type_t type)
 
static void RequireCompleteType (CompilerType type)
 Complete a type from debug info, or mark it as forcefully completed if there is no definition of the type in the current Module.
 
- Static Public Member Functions inherited from lldb_private::TypeSystem
static lldb::TypeSystemSP CreateInstance (lldb::LanguageType language, Module *module)
 
static lldb::TypeSystemSP CreateInstance (lldb::LanguageType language, Target *target)
 

Private Types

typedef llvm::DenseMap< const clang::Decl *, ClangASTMetadataDeclMetadataMap
 
typedef llvm::DenseMap< const clang::Type *, ClangASTMetadataTypeMetadataMap
 
typedef llvm::DenseMap< const clang::CXXRecordDecl *, clang::AccessSpecifier > CXXRecordDeclAccessMap
 

Private Member Functions

clang::PrintingPolicy GetTypePrintingPolicy ()
 Returns the PrintingPolicy used when generating the internal type names.
 
std::string GetTypeNameForDecl (const clang::NamedDecl *named_decl, bool qualified=true)
 Returns the internal type name for the given NamedDecl using the type printing policy.
 
const clang::ClassTemplateSpecializationDecl * GetAsTemplateSpecialization (lldb::opaque_compiler_type_t type)
 
bool IsTypeImpl (lldb::opaque_compiler_type_t type, llvm::function_ref< bool(clang::QualType)> predicate) const
 
 TypeSystemClang (const TypeSystemClang &)
 
const TypeSystemClangoperator= (const TypeSystemClang &)
 
void CreateASTContext ()
 Creates the internal ASTContext.
 
void SetTargetTriple (llvm::StringRef target_triple)
 

Private Attributes

std::string m_target_triple
 
std::unique_ptr< clang::ASTContext > m_ast_up
 
std::unique_ptr< clang::LangOptions > m_language_options_up
 
std::unique_ptr< clang::FileManager > m_file_manager_up
 
std::unique_ptr< clang::SourceManager > m_source_manager_up
 
std::unique_ptr< clang::DiagnosticsEngine > m_diagnostics_engine_up
 
std::unique_ptr< clang::DiagnosticConsumer > m_diagnostic_consumer_up
 
std::shared_ptr< clang::TargetOptions > m_target_options_rp
 
std::unique_ptr< clang::TargetInfo > m_target_info_up
 
std::unique_ptr< clang::IdentifierTable > m_identifier_table_up
 
std::unique_ptr< clang::SelectorTable > m_selector_table_up
 
std::unique_ptr< clang::Builtin::Context > m_builtins_up
 
std::unique_ptr< clang::HeaderSearch > m_header_search_up
 
std::unique_ptr< clang::ModuleMap > m_module_map_up
 
std::unique_ptr< DWARFASTParserClangm_dwarf_ast_parser_up
 
std::unique_ptr< PDBASTParserm_pdb_ast_parser_up
 
std::unique_ptr< npdb::PdbAstBuilderm_native_pdb_ast_parser_up
 
std::unique_ptr< clang::MangleContext > m_mangle_ctx_up
 
uint32_t m_pointer_byte_size = 0
 
bool m_ast_owned = false
 
std::string m_display_name
 A string describing what this TypeSystemClang represents (e.g., AST for debug information, an expression, some other utility ClangAST).
 
DeclMetadataMap m_decl_metadata
 Maps Decls to their associated ClangASTMetadata.
 
TypeMetadataMap m_type_metadata
 Maps Types to their associated ClangASTMetadata.
 
CXXRecordDeclAccessMap m_cxx_record_decl_access
 Maps CXXRecordDecl to their most recent added method/field's AccessSpecifier.
 
clang::Sema * m_sema = nullptr
 The sema associated that is currently used to build this ASTContext.
 

Static Private Attributes

static char ID
 

Additional Inherited Members

- Protected Attributes inherited from lldb_private::TypeSystem
SymbolFilem_sym_file = nullptr
 
bool m_has_forcefully_completed_types = false
 Used for reporting statistics.
 

Detailed Description

A TypeSystem implementation based on Clang.

This class uses a single clang::ASTContext as the backend for storing its types and declarations. Every clang::ASTContext should also just have a single associated TypeSystemClang instance that manages it.

The clang::ASTContext instance can either be created by TypeSystemClang itself or it can adopt an existing clang::ASTContext (for example, when it is necessary to provide a TypeSystem interface for an existing clang::ASTContext that was created by clang::CompilerInstance).

Definition at line 107 of file TypeSystemClang.h.

Member Typedef Documentation

◆ CompleteObjCInterfaceDeclCallback

typedef void(* lldb_private::TypeSystemClang::CompleteObjCInterfaceDeclCallback) (void *baton, clang::ObjCInterfaceDecl *)

Definition at line 113 of file TypeSystemClang.h.

◆ CompleteTagDeclCallback

typedef void(* lldb_private::TypeSystemClang::CompleteTagDeclCallback) (void *baton, clang::TagDecl *)

Definition at line 112 of file TypeSystemClang.h.

◆ CXXRecordDeclAccessMap

typedef llvm::DenseMap<const clang::CXXRecordDecl *, clang::AccessSpecifier> lldb_private::TypeSystemClang::CXXRecordDeclAccessMap
private

Definition at line 1195 of file TypeSystemClang.h.

◆ DeclMetadataMap

typedef llvm::DenseMap<const clang::Decl *, ClangASTMetadata> lldb_private::TypeSystemClang::DeclMetadataMap
private

Definition at line 1186 of file TypeSystemClang.h.

◆ TypeMetadataMap

typedef llvm::DenseMap<const clang::Type *, ClangASTMetadata> lldb_private::TypeSystemClang::TypeMetadataMap
private

Definition at line 1190 of file TypeSystemClang.h.

Constructor & Destructor Documentation

◆ TypeSystemClang() [1/3]

TypeSystemClang::TypeSystemClang ( llvm::StringRef  name,
llvm::Triple  triple 
)
explicit

Constructs a TypeSystemClang with an ASTContext using the given triple.

Parameters
nameThe name for the TypeSystemClang (for logging purposes)
tripleThe llvm::Triple used for the ASTContext. The triple defines certain characteristics of the ASTContext and its types (e.g., whether certain primitive types exist or what their signedness is).

Definition at line 496 of file TypeSystemClang.cpp.

References CreateASTContext(), m_display_name, and SetTargetTriple().

◆ TypeSystemClang() [2/3]

lldb_private::TypeSystemClang::TypeSystemClang ( llvm::StringRef  name,
clang::ASTContext &  existing_ctxt 
)
explicit

Constructs a TypeSystemClang that uses an existing ASTContext internally.

Useful when having an existing ASTContext created by Clang.

Parameters
nameThe name for the TypeSystemClang (for logging purposes)
existing_ctxtAn existing ASTContext.

◆ ~TypeSystemClang()

TypeSystemClang::~TypeSystemClang ( )
override

Definition at line 516 of file TypeSystemClang.cpp.

References Finalize().

◆ TypeSystemClang() [3/3]

lldb_private::TypeSystemClang::TypeSystemClang ( const TypeSystemClang )
private

Member Function Documentation

◆ AddConstModifier()

CompilerType TypeSystemClang::AddConstModifier ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4505 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ AddEnumerationValueToEnumerationType() [1/2]

clang::EnumConstantDecl * TypeSystemClang::AddEnumerationValueToEnumerationType ( const CompilerType enum_type,
const Declaration decl,
const char *  name,
const llvm::APSInt &  value 
)

◆ AddEnumerationValueToEnumerationType() [2/2]

clang::EnumConstantDecl * TypeSystemClang::AddEnumerationValueToEnumerationType ( const CompilerType enum_type,
const Declaration decl,
const char *  name,
int64_t  enum_value,
uint32_t  enum_value_bit_size 
)

◆ AddFieldToRecordType()

clang::FieldDecl * TypeSystemClang::AddFieldToRecordType ( const CompilerType type,
llvm::StringRef  name,
const CompilerType field_type,
lldb::AccessType  access,
uint32_t  bitfield_bit_size 
)
static

◆ AddMethodOverridesForCXXRecordType()

void TypeSystemClang::AddMethodOverridesForCXXRecordType ( lldb::opaque_compiler_type_t  type)

◆ AddMethodToCXXRecordType()

clang::CXXMethodDecl * TypeSystemClang::AddMethodToCXXRecordType ( lldb::opaque_compiler_type_t  type,
llvm::StringRef  name,
const char *  mangled_name,
const CompilerType method_type,
lldb::AccessType  access,
bool  is_virtual,
bool  is_static,
bool  is_inline,
bool  is_explicit,
bool  is_attr_used,
bool  is_artificial 
)

◆ AddMethodToObjCObjectType()

clang::ObjCMethodDecl * TypeSystemClang::AddMethodToObjCObjectType ( const CompilerType type,
const char *  name,
const CompilerType method_compiler_type,
bool  is_artificial,
bool  is_variadic,
bool  is_objc_direct_call 
)
static

◆ AddObjCClassProperty()

bool TypeSystemClang::AddObjCClassProperty ( const CompilerType type,
const char *  property_name,
const CompilerType property_compiler_type,
clang::ObjCIvarDecl *  ivar_decl,
const char *  property_setter_name,
const char *  property_getter_name,
uint32_t  property_attributes,
ClangASTMetadata metadata 
)
static

◆ AddRestrictModifier()

CompilerType TypeSystemClang::AddRestrictModifier ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4525 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ AddVariableToRecordType()

clang::VarDecl * TypeSystemClang::AddVariableToRecordType ( const CompilerType type,
llvm::StringRef  name,
const CompilerType var_type,
lldb::AccessType  access 
)
static

◆ AddVolatileModifier()

CompilerType TypeSystemClang::AddVolatileModifier ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4515 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ AreTypesSame()

bool TypeSystemClang::AreTypesSame ( CompilerType  type1,
CompilerType  type2,
bool  ignore_qualifiers = false 
)
static

◆ BaseSpecifierIsEmpty()

bool TypeSystemClang::BaseSpecifierIsEmpty ( const clang::CXXBaseSpecifier *  b)

Definition at line 1818 of file TypeSystemClang.cpp.

References RecordHasFields().

Referenced by GetIndexForRecordBase(), and GetNumBaseClasses().

◆ BuildIndirectFields()

void TypeSystemClang::BuildIndirectFields ( const CompilerType type)
static

◆ CanPassInRegisters()

bool TypeSystemClang::CanPassInRegisters ( const CompilerType type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3597 of file TypeSystemClang.cpp.

References GetAsRecordDecl().

◆ CheckOverloadedOperatorKindParameterCount()

bool TypeSystemClang::CheckOverloadedOperatorKindParameterCount ( bool  is_method,
clang::OverloadedOperatorKind  op_kind,
uint32_t  num_params 
)
static

◆ classof()

static bool lldb_private::TypeSystemClang::classof ( const TypeSystem ts)
inlinestatic

Definition at line 118 of file TypeSystemClang.h.

References ID, and lldb_private::TypeSystem::isA().

◆ CompleteObjCInterfaceDecl()

void TypeSystemClang::CompleteObjCInterfaceDecl ( clang::ObjCInterfaceDecl *  decl)

◆ CompleteTagDecl()

void TypeSystemClang::CompleteTagDecl ( clang::TagDecl *  decl)

◆ CompleteTagDeclarationDefinition()

bool TypeSystemClang::CompleteTagDeclarationDefinition ( const CompilerType type)
static

◆ ConvertAccessTypeToAccessSpecifier()

clang::AccessSpecifier TypeSystemClang::ConvertAccessTypeToAccessSpecifier ( lldb::AccessType  access)
static

◆ CountDeclLevels()

uint32_t TypeSystemClang::CountDeclLevels ( clang::DeclContext *  frame_decl_ctx,
clang::DeclContext *  child_decl_ctx,
ConstString child_name = nullptr,
CompilerType child_type = nullptr 
)

◆ CreateArrayType()

CompilerType TypeSystemClang::CreateArrayType ( const CompilerType element_type,
size_t  element_count,
bool  is_vector 
)

◆ CreateASTContext()

void TypeSystemClang::CreateASTContext ( )
private

◆ CreateBaseClassSpecifier()

std::unique_ptr< clang::CXXBaseSpecifier > TypeSystemClang::CreateBaseClassSpecifier ( lldb::opaque_compiler_type_t  type,
lldb::AccessType  access,
bool  is_virtual,
bool  base_of_class 
)

◆ CreateBlockDeclaration()

clang::BlockDecl * TypeSystemClang::CreateBlockDeclaration ( clang::DeclContext *  ctx,
OptionalClangModuleID  owning_module 
)

◆ CreateBlockPointerType()

CompilerType TypeSystemClang::CreateBlockPointerType ( const CompilerType function_type)

◆ CreateClassTemplateDecl()

ClassTemplateDecl * TypeSystemClang::CreateClassTemplateDecl ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
lldb::AccessType  access_type,
llvm::StringRef  class_name,
int  kind,
const TemplateParameterInfos infos 
)

◆ CreateClassTemplateSpecializationDecl()

ClassTemplateSpecializationDecl * TypeSystemClang::CreateClassTemplateSpecializationDecl ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
clang::ClassTemplateDecl *  class_template_decl,
int  kind,
const TemplateParameterInfos infos 
)

◆ CreateClassTemplateSpecializationType()

CompilerType TypeSystemClang::CreateClassTemplateSpecializationType ( clang::ClassTemplateSpecializationDecl *  class_template_specialization_decl)

Definition at line 1673 of file TypeSystemClang.cpp.

References getASTContext(), and GetType().

Referenced by DWARFASTParserClang::ParseStructureLikeDIE().

◆ CreateDeclContext()

CompilerDeclContext TypeSystemClang::CreateDeclContext ( clang::DeclContext *  ctx)

◆ CreateEnumerationType()

CompilerType TypeSystemClang::CreateEnumerationType ( llvm::StringRef  name,
clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
const Declaration decl,
const CompilerType integer_qual_type,
bool  is_scoped 
)

◆ CreateFunctionDeclaration()

FunctionDecl * TypeSystemClang::CreateFunctionDeclaration ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
llvm::StringRef  name,
const CompilerType function_Type,
clang::StorageClass  storage,
bool  is_inline 
)

◆ CreateFunctionTemplateDecl()

clang::FunctionTemplateDecl * TypeSystemClang::CreateFunctionTemplateDecl ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
clang::FunctionDecl *  func_decl,
const TemplateParameterInfos infos 
)

◆ CreateFunctionTemplateSpecializationInfo()

void TypeSystemClang::CreateFunctionTemplateSpecializationInfo ( clang::FunctionDecl *  func_decl,
clang::FunctionTemplateDecl *  Template,
const TemplateParameterInfos infos 
)

◆ CreateFunctionType()

CompilerType TypeSystemClang::CreateFunctionType ( const CompilerType result_type,
const CompilerType args,
unsigned  num_args,
bool  is_variadic,
unsigned  type_quals,
clang::CallingConv  cc = clang::CC_C,
clang::RefQualifierKind  ref_qual = clang::RQ_None 
)

◆ CreateGenericFunctionPrototype()

CompilerType TypeSystemClang::CreateGenericFunctionPrototype ( )
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4593 of file TypeSystemClang.cpp.

References getASTContext(), and GetType().

◆ CreateInstance()

lldb::TypeSystemSP TypeSystemClang::CreateInstance ( lldb::LanguageType  language,
lldb_private::Module module,
Target target 
)
static

◆ CreateMemberPointerType()

CompilerType TypeSystemClang::CreateMemberPointerType ( const CompilerType type,
const CompilerType pointee_type 
)
static

◆ CreateObjCClass()

CompilerType TypeSystemClang::CreateObjCClass ( llvm::StringRef  name,
clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
bool  isForwardDecl,
bool  isInternal,
ClangASTMetadata metadata = nullptr 
)

Definition at line 1795 of file TypeSystemClang.cpp.

References getASTContext(), GetType(), SetMetadata(), and SetOwningModule().

Referenced by CreateRecordType().

◆ CreateParameterDeclaration()

ParmVarDecl * TypeSystemClang::CreateParameterDeclaration ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
const char *  name,
const CompilerType param_type,
int  storage,
bool  add_decl = false 
)

◆ CreateRecordType()

CompilerType TypeSystemClang::CreateRecordType ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
lldb::AccessType  access_type,
llvm::StringRef  name,
int  kind,
lldb::LanguageType  language,
ClangASTMetadata metadata = nullptr,
bool  exports_symbols = false 
)

◆ CreateStructForIdentifier()

CompilerType TypeSystemClang::CreateStructForIdentifier ( llvm::StringRef  type_name,
const std::initializer_list< std::pair< const char *, CompilerType > > &  type_fields,
bool  packed = false 
)

◆ CreateTemplateTemplateParmDecl()

TemplateTemplateParmDecl * TypeSystemClang::CreateTemplateTemplateParmDecl ( const char *  template_name)

◆ CreateTypedef()

CompilerType TypeSystemClang::CreateTypedef ( lldb::opaque_compiler_type_t  type,
const char *  name,
const CompilerDeclContext decl_ctx,
uint32_t  opaque_payload 
)
overridevirtual

Using the current type, create a new typedef to that type using "typedef_name" as the name and "decl_ctx" as the decl context.

Parameters
opaque_payloadis an opaque TypePayloadClang.

Reimplemented from lldb_private::TypeSystem.

Definition at line 4534 of file TypeSystemClang.cpp.

References DeclContextGetAsDeclContext(), getASTContext(), GetQualType(), GetType(), and SetOwningModule().

◆ CreateUsingDeclaration()

clang::UsingDecl * TypeSystemClang::CreateUsingDeclaration ( clang::DeclContext *  current_decl_ctx,
OptionalClangModuleID  owning_module,
clang::NamedDecl *  target 
)

Definition at line 1958 of file TypeSystemClang.cpp.

References getASTContext(), and SetOwningModule().

Referenced by DWARFASTParserClang::GetClangDeclForDIE().

◆ CreateUsingDirectiveDeclaration()

clang::UsingDirectiveDecl * TypeSystemClang::CreateUsingDirectiveDeclaration ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
clang::NamespaceDecl *  ns_decl 
)

◆ CreateVariableDeclaration()

clang::VarDecl * TypeSystemClang::CreateVariableDeclaration ( clang::DeclContext *  decl_context,
OptionalClangModuleID  owning_module,
const char *  name,
clang::QualType  type 
)

◆ DeclContextFindDeclByName()

std::vector< CompilerDecl > TypeSystemClang::DeclContextFindDeclByName ( void *  opaque_decl_ctx,
ConstString  name,
const bool  ignore_using_decls 
)
overridevirtual

◆ DeclContextGetAsCXXMethodDecl()

CXXMethodDecl * TypeSystemClang::DeclContextGetAsCXXMethodDecl ( const CompilerDeclContext dc)
static

◆ DeclContextGetAsDeclContext()

clang::DeclContext * TypeSystemClang::DeclContextGetAsDeclContext ( const CompilerDeclContext dc)
static

◆ DeclContextGetAsFunctionDecl()

clang::FunctionDecl * TypeSystemClang::DeclContextGetAsFunctionDecl ( const CompilerDeclContext dc)
static

◆ DeclContextGetAsNamespaceDecl()

clang::NamespaceDecl * TypeSystemClang::DeclContextGetAsNamespaceDecl ( const CompilerDeclContext dc)
static

◆ DeclContextGetAsObjCMethodDecl()

ObjCMethodDecl * TypeSystemClang::DeclContextGetAsObjCMethodDecl ( const CompilerDeclContext dc)
static

◆ DeclContextGetCompilerContext()

std::vector< lldb_private::CompilerContext > TypeSystemClang::DeclContextGetCompilerContext ( void *  opaque_decl_ctx)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9369 of file TypeSystemClang.cpp.

References InsertCompilerContext().

◆ DeclContextGetLanguage()

lldb::LanguageType TypeSystemClang::DeclContextGetLanguage ( void *  opaque_decl_ctx)
overridevirtual

◆ DeclContextGetMetaData()

ClangASTMetadata * TypeSystemClang::DeclContextGetMetaData ( const CompilerDeclContext dc,
const clang::Decl *  object 
)
static

◆ DeclContextGetName()

ConstString TypeSystemClang::DeclContextGetName ( void *  opaque_decl_ctx)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 9323 of file TypeSystemClang.cpp.

References GetTypePrintingPolicy().

Referenced by InsertCompilerContext().

◆ DeclContextGetScopeQualifiedName()

ConstString TypeSystemClang::DeclContextGetScopeQualifiedName ( void *  opaque_decl_ctx)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 9340 of file TypeSystemClang.cpp.

References GetTypeNameForDecl().

◆ DeclContextGetTypeSystemClang()

clang::ASTContext * TypeSystemClang::DeclContextGetTypeSystemClang ( const CompilerDeclContext dc)
static

◆ DeclContextIsClassMethod()

bool TypeSystemClang::DeclContextIsClassMethod ( void *  opaque_decl_ctx)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 9350 of file TypeSystemClang.cpp.

References GetMetadata().

◆ DeclContextIsContainedInLookup()

bool TypeSystemClang::DeclContextIsContainedInLookup ( void *  opaque_decl_ctx,
void *  other_opaque_decl_ctx 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 9376 of file TypeSystemClang.cpp.

◆ DeclGetCompilerContext()

std::vector< lldb_private::CompilerContext > TypeSystemClang::DeclGetCompilerContext ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9093 of file TypeSystemClang.cpp.

References DeclGetName(), GetCompilerKind(), and InsertCompilerContext().

◆ DeclGetConstantValue()

Scalar TypeSystemClang::DeclGetConstantValue ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9127 of file TypeSystemClang.cpp.

References getASTContext().

◆ DeclGetDeclContext()

CompilerDeclContext TypeSystemClang::DeclGetDeclContext ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9021 of file TypeSystemClang.cpp.

References CreateDeclContext().

◆ DeclGetFunctionArgumentType()

CompilerType TypeSystemClang::DeclGetFunctionArgumentType ( void *  opaque_decl,
size_t  arg_idx 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9109 of file TypeSystemClang.cpp.

References GetType().

◆ DeclGetFunctionNumArguments()

size_t TypeSystemClang::DeclGetFunctionNumArguments ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9038 of file TypeSystemClang.cpp.

◆ DeclGetFunctionReturnType()

CompilerType TypeSystemClang::DeclGetFunctionReturnType ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 9027 of file TypeSystemClang.cpp.

References GetType().

◆ DeclGetMangledName()

ConstString TypeSystemClang::DeclGetMangledName ( void *  opaque_decl)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 8991 of file TypeSystemClang.cpp.

References getMangleContext().

◆ DeclGetName()

ConstString TypeSystemClang::DeclGetName ( void *  opaque_decl)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 8981 of file TypeSystemClang.cpp.

Referenced by DeclGetCompilerContext().

◆ dump()

LLVM_DUMP_METHOD void TypeSystemClang::dump ( lldb::opaque_compiler_type_t  type) const
overridevirtual

Convenience LLVM-style dump method for use in the debugger only.

In contrast to the other Dump() methods this directly invokes clang::QualType::dump().

Implements lldb_private::TypeSystem.

Definition at line 8471 of file TypeSystemClang.cpp.

References GetQualType().

◆ Dump()

void TypeSystemClang::Dump ( llvm::raw_ostream &  output)
overridevirtual

◆ DumpDeclContextHiearchy()

void TypeSystemClang::DumpDeclContextHiearchy ( clang::DeclContext *  decl_ctx)
static

Definition at line 2376 of file TypeSystemClang.cpp.

References DumpDeclContextHiearchy().

Referenced by DumpDeclContextHiearchy(), and DumpDeclHiearchy().

◆ DumpDeclHiearchy()

void TypeSystemClang::DumpDeclHiearchy ( clang::Decl *  decl)
static

Definition at line 2390 of file TypeSystemClang.cpp.

References DumpDeclContextHiearchy().

◆ DumpFromSymbolFile()

void TypeSystemClang::DumpFromSymbolFile ( Stream s,
llvm::StringRef  symbol_name 
)

◆ DumpTypeDescription() [1/2]

void TypeSystemClang::DumpTypeDescription ( lldb::opaque_compiler_type_t  type,
lldb::DescriptionLevel  level = lldb::eDescriptionLevelFull 
)
overridevirtual

◆ DumpTypeDescription() [2/2]

void TypeSystemClang::DumpTypeDescription ( lldb::opaque_compiler_type_t  type,
Stream s,
lldb::DescriptionLevel  level = lldb::eDescriptionLevelFull 
)
overridevirtual

Print a description of the type to a stream.

The exact implementation varies, but the expectation is that eDescriptionLevelFull returns a source-like representation of the type, whereas eDescriptionLevelVerbose does a dump of the underlying AST if applicable.

Implements lldb_private::TypeSystem.

Definition at line 8742 of file TypeSystemClang.cpp.

References lldb::eDescriptionLevelVerbose, getASTContext(), GetCompleteType(), lldb_private::Stream::GetIndentLevel(), GetQualType(), GetTypeNameForDecl(), lldb_private::Stream::PutCString(), RemoveWrappingTypes(), and lldb_private::Stream::Write().

◆ DumpTypeName()

void TypeSystemClang::DumpTypeName ( const CompilerType type)
static

◆ DumpTypeValue()

bool TypeSystemClang::DumpTypeValue ( lldb::opaque_compiler_type_t  type,
Stream s,
lldb::Format  format,
const DataExtractor data,
lldb::offset_t  data_offset,
size_t  data_byte_size,
uint32_t  bitfield_bit_size,
uint32_t  bitfield_bit_offset,
ExecutionContextScope exe_scope 
)
overridevirtual

◆ FieldIsBitfield()

bool TypeSystemClang::FieldIsBitfield ( clang::FieldDecl *  field,
uint32_t &  bitfield_bit_size 
)

Definition at line 1740 of file TypeSystemClang.cpp.

References getASTContext(), and UINT32_MAX.

Referenced by GetChildCompilerTypeAtIndex().

◆ Finalize()

void TypeSystemClang::Finalize ( )
overridevirtual

◆ ForEachEnumerator()

void TypeSystemClang::ForEachEnumerator ( lldb::opaque_compiler_type_t  type,
std::function< bool(const CompilerType &integer_type, ConstString name, const llvm::APSInt &value)> const &  callback 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 5463 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and GetType().

◆ GetArrayElementType()

CompilerType TypeSystemClang::GetArrayElementType ( lldb::opaque_compiler_type_t  type,
ExecutionContextScope exe_scope 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4161 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ GetArrayType()

CompilerType TypeSystemClang::GetArrayType ( lldb::opaque_compiler_type_t  type,
uint64_t  size 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4177 of file TypeSystemClang.cpp.

References getASTContext(), GetCanonicalQualType(), and GetType().

◆ GetAsCXXRecordDecl()

clang::CXXRecordDecl * TypeSystemClang::GetAsCXXRecordDecl ( lldb::opaque_compiler_type_t  type)
static

◆ GetAsDeclContext()

static clang::DeclContext * lldb_private::TypeSystemClang::GetAsDeclContext ( clang::FunctionDecl *  function_decl)
static

◆ GetAsEnumDecl()

clang::EnumDecl * TypeSystemClang::GetAsEnumDecl ( const CompilerType type)
static

◆ GetAsObjCInterfaceDecl()

clang::ObjCInterfaceDecl * TypeSystemClang::GetAsObjCInterfaceDecl ( const CompilerType type)
static

◆ GetAsRecordDecl()

clang::RecordDecl * TypeSystemClang::GetAsRecordDecl ( const CompilerType type)
static

◆ GetAsTagDecl()

clang::TagDecl * TypeSystemClang::GetAsTagDecl ( const CompilerType type)
static

◆ getASTContext()

ASTContext & TypeSystemClang::getASTContext ( )

Returns the clang::ASTContext instance managed by this TypeSystemClang.

Definition at line 633 of file TypeSystemClang.cpp.

References m_ast_up.

Referenced by AddEnumerationValueToEnumerationType(), PDBASTParser::AddEnumValue(), AddFieldToRecordType(), AddMethodToCXXRecordType(), AddMethodToObjCObjectType(), AddObjCClassProperty(), PDBASTParser::AddRecordMembers(), lldb_private::AppleObjCTypeEncodingParser::BuildObjCObjectPointerType(), lldb_private::AppleObjCTypeEncodingParser::BuildType(), lldb_private::npdb::PdbAstBuilder::CompleteTagDecl(), lldb_private::ClangASTImporter::CopyType(), CreateArrayType(), CreateBaseClassSpecifier(), CreateBlockDeclaration(), CreateClassTemplateDecl(), CreateClassTemplateSpecializationDecl(), CreateClassTemplateSpecializationType(), CreateDeclContext(), CreateEnumerationType(), CreateFunctionDeclaration(), CreateFunctionTemplateDecl(), CreateFunctionType(), CreateGenericFunctionPrototype(), PDBASTParser::CreateLLDBTypeFromPDBType(), CreateObjCClass(), CreateParameterDeclaration(), lldb_private::npdb::PdbAstBuilder::CreatePointerType(), CreateRecordType(), lldb_private::npdb::PdbAstBuilder::CreateSimpleType(), CreateTemplateTemplateParmDecl(), CreateTypedef(), CreateUsingDeclaration(), CreateUsingDirectiveDeclaration(), CreateVariableDeclaration(), DeclContextGetTypeSystemClang(), DeclGetConstantValue(), lldb_private::ClangASTImporter::DeportType(), lldb_private::ClangExpressionDeclMap::DeportType(), DumpFromSymbolFile(), DumpTypeDescription(), DumpTypeValue(), DWARFASTParserClang::ExtractIntFromFormValue(), FieldIsBitfield(), lldb_private::ScratchTypeSystemClang::ForgetSource(), GetArrayType(), lldb_private::NameSearchContext::GetASTContext(), GetAtomicType(), GetBasicType(), GetBitSize(), GetBuiltinTypeForDWARFEncodingAndBitSize(), GetBuiltinTypeForEncodingAndBitSize(), GetBuiltinTypeForPDBEncodingAndBitSize(), GetChildCompilerTypeAtIndex(), GetCompilerDecl(), GetCompleteDecl(), GetCompleteType(), GetCStringType(), GetDeclarationName(), PDBASTParser::GetDeclForSymbol(), GetDirectBaseClassAtIndex(), GetDirectNestedTypeWithName(), GetDisplayTypeName(), GetFieldAtIndex(), GetFloatTypeSemantics(), GetFullyUnqualifiedType(), GetIndexOfChildMemberWithName(), GetIntTypeFromBitSize(), GetLValueReferenceType(), getMangleContext(), GetMemberFunctionAtIndex(), GetMinimumLanguage(), GetNumChildren(), GetNumMemberFunctions(), GetOrCreateClangModule(), GetPointerSizedIntType(), GetPointerType(), GetRValueReferenceType(), GetStaticFieldWithName(), getTargetInfo(), GetTranslationUnitDecl(), GetType(), GetTypeBitAlign(), GetTypeForIdentifier(), GetTypeInfo(), GetTypePrintingPolicy(), GetUniqueNamespaceDeclaration(), GetVirtualBaseClassAtIndex(), lldb_private::ClangASTSource::InstallASTContext(), IsCompleteType(), IsHomogeneousAggregate(), DWARFASTParserClang::ParseSubroutine(), DWARFASTParserClang::ParseTemplateDIE(), PrintTemplateParams(), SetExternalSource(), and SetObjCSuperClass().

◆ GetASTContext()

TypeSystemClang * TypeSystemClang::GetASTContext ( clang::ASTContext *  ast_ctx)
static

◆ GetAsTemplateSpecialization()

const clang::ClassTemplateSpecializationDecl * TypeSystemClang::GetAsTemplateSpecialization ( lldb::opaque_compiler_type_t  type)
private

◆ GetAsTypedefDecl()

clang::TypedefNameDecl * TypeSystemClang::GetAsTypedefDecl ( const CompilerType type)
static

◆ GetAtomicType()

CompilerType TypeSystemClang::GetAtomicType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4498 of file TypeSystemClang.cpp.

References getASTContext(), GetQualType(), and GetType().

◆ GetBasicType()

CompilerType TypeSystemClang::GetBasicType ( lldb::BasicType  type)

◆ GetBasicTypeEnumeration() [1/2]

lldb::BasicType TypeSystemClang::GetBasicTypeEnumeration ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetBasicTypeEnumeration() [2/2]

lldb::BasicType TypeSystemClang::GetBasicTypeEnumeration ( llvm::StringRef  name)
static

◆ GetBasicTypeFromAST()

CompilerType TypeSystemClang::GetBasicTypeFromAST ( lldb::BasicType  basic_type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4589 of file TypeSystemClang.cpp.

References GetBasicType().

◆ GetBitSize()

std::optional< uint64_t > TypeSystemClang::GetBitSize ( lldb::opaque_compiler_type_t  type,
ExecutionContextScope exe_scope 
)
overridevirtual

◆ GetBuiltinTypeByName()

CompilerType TypeSystemClang::GetBuiltinTypeByName ( ConstString  name)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 5384 of file TypeSystemClang.cpp.

References GetBasicType(), and GetBasicTypeEnumeration().

◆ GetBuiltinTypeForDWARFEncodingAndBitSize()

CompilerType TypeSystemClang::GetBuiltinTypeForDWARFEncodingAndBitSize ( llvm::StringRef  type_name,
uint32_t  dw_ate,
uint32_t  bit_size 
)

◆ GetBuiltinTypeForEncodingAndBitSize()

CompilerType TypeSystemClang::GetBuiltinTypeForEncodingAndBitSize ( lldb::Encoding  encoding,
size_t  bit_size 
)
overridevirtual

◆ GetByteSize()

std::optional< uint64_t > lldb_private::TypeSystemClang::GetByteSize ( lldb::opaque_compiler_type_t  type,
ExecutionContextScope exe_scope 
)
inline

Definition at line 822 of file TypeSystemClang.h.

References GetBitSize().

Referenced by GetPointerByteSize().

◆ GetCanonicalQualType()

static clang::QualType lldb_private::TypeSystemClang::GetCanonicalQualType ( lldb::opaque_compiler_type_t  type)
inlinestatic

◆ GetCanonicalType()

CompilerType TypeSystemClang::GetCanonicalType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4195 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and GetType().

◆ GetChildCompilerTypeAtIndex()

CompilerType TypeSystemClang::GetChildCompilerTypeAtIndex ( lldb::opaque_compiler_type_t  type,
ExecutionContext exe_ctx,
size_t  idx,
bool  transparent_pointers,
bool  omit_empty_base_classes,
bool  ignore_array_bounds,
std::string &  child_name,
uint32_t &  child_byte_size,
int32_t &  child_byte_offset,
uint32_t &  child_bitfield_bit_size,
uint32_t &  child_bitfield_bit_offset,
bool &  child_is_base_class,
bool &  child_is_deref_of_parent,
ValueObject valobj,
uint64_t &  language_flags 
)
overridevirtual

◆ GetCompilerDecl()

CompilerDecl lldb_private::TypeSystemClang::GetCompilerDecl ( clang::Decl *  decl)
inline

Creates a CompilerDecl from the given Decl with the current TypeSystemClang instance as its typesystem.

The Decl has to come from the ASTContext of this TypeSystemClang.

Definition at line 542 of file TypeSystemClang.h.

References getASTContext().

Referenced by DeclContextFindDeclByName(), SymbolFilePDB::GetDeclForUID(), DWARFASTParserClang::GetDeclForUIDFromDWARF(), GetMemberFunctionAtIndex(), and lldb_private::npdb::PdbAstBuilder::ToCompilerDecl().

◆ GetCompilerDeclContextForType()

CompilerDeclContext TypeSystemClang::GetCompilerDeclContextForType ( const CompilerType type)
overridevirtual

Returns the direct parent context of specified type.

Reimplemented from lldb_private::TypeSystem.

Definition at line 2508 of file TypeSystemClang.cpp.

References CreateDeclContext(), and GetDeclContextForType().

◆ GetCompleteDecl() [1/2]

bool TypeSystemClang::GetCompleteDecl ( clang::ASTContext *  ast,
clang::Decl *  decl 
)
static

Definition at line 2412 of file TypeSystemClang.cpp.

◆ GetCompleteDecl() [2/2]

bool lldb_private::TypeSystemClang::GetCompleteDecl ( clang::Decl *  decl)
inline

◆ GetCompleteType()

bool TypeSystemClang::GetCompleteType ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetCStringType()

CompilerType TypeSystemClang::GetCStringType ( bool  is_const)

Definition at line 1100 of file TypeSystemClang.cpp.

References getASTContext(), and GetType().

◆ GetCXXClassName()

std::optional< std::string > TypeSystemClang::GetCXXClassName ( const CompilerType type)
static

◆ GetCXXRecordDeclAccess()

clang::AccessSpecifier TypeSystemClang::GetCXXRecordDeclAccess ( const clang::CXXRecordDecl *  object)

Definition at line 2495 of file TypeSystemClang.cpp.

References m_cxx_record_decl_access.

Referenced by AddMethodToCXXRecordType().

◆ GetDeclarationName()

clang::DeclarationName TypeSystemClang::GetDeclarationName ( llvm::StringRef  name,
const CompilerType function_clang_type 
)

◆ GetDeclContextForType() [1/2]

clang::DeclContext * TypeSystemClang::GetDeclContextForType ( clang::QualType  type)
static

◆ GetDeclContextForType() [2/2]

clang::DeclContext * TypeSystemClang::GetDeclContextForType ( const CompilerType type)
static

◆ GetDirectBaseClassAtIndex()

CompilerType TypeSystemClang::GetDirectBaseClassAtIndex ( lldb::opaque_compiler_type_t  type,
size_t  idx,
uint32_t *  bit_offset_ptr 
)
overridevirtual

◆ GetDirectNestedTypeWithName()

CompilerType TypeSystemClang::GetDirectNestedTypeWithName ( lldb::opaque_compiler_type_t  type,
llvm::StringRef  name 
)
overridevirtual

◆ getDisplayName()

llvm::StringRef lldb_private::TypeSystemClang::getDisplayName ( ) const
inline

◆ GetDisplayTypeName()

ConstString TypeSystemClang::GetDisplayTypeName ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3714 of file TypeSystemClang.cpp.

References getASTContext(), and GetQualType().

Referenced by GetNumChildren().

◆ GetDWARFParser()

DWARFASTParser * TypeSystemClang::GetDWARFParser ( )
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 8939 of file TypeSystemClang.cpp.

References m_dwarf_ast_parser_up.

◆ GetEncoding()

lldb::Encoding TypeSystemClang::GetEncoding ( lldb::opaque_compiler_type_t  type,
uint64_t &  count 
)
overridevirtual

◆ GetEnumerationIntegerType() [1/2]

CompilerType TypeSystemClang::GetEnumerationIntegerType ( CompilerType  type)

Returns the underlying integer type for an enum type.

If the given type is invalid or not an enum-type, the function returns an invalid CompilerType.

Definition at line 8440 of file TypeSystemClang.cpp.

References lldb_private::ClangUtil::GetQualType(), and GetType().

◆ GetEnumerationIntegerType() [2/2]

CompilerType TypeSystemClang::GetEnumerationIntegerType ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetFieldAtIndex()

CompilerType TypeSystemClang::GetFieldAtIndex ( lldb::opaque_compiler_type_t  type,
size_t  idx,
std::string &  name,
uint64_t *  bit_offset_ptr,
uint32_t *  bitfield_bit_size_ptr,
bool *  is_bitfield_ptr 
)
overridevirtual

◆ GetFloatTypeFromBitSize()

static CompilerType lldb_private::TypeSystemClang::GetFloatTypeFromBitSize ( clang::ASTContext *  ast,
size_t  bit_size 
)
static

◆ GetFloatTypeSemantics()

const llvm::fltSemantics & TypeSystemClang::GetFloatTypeSemantics ( size_t  byte_size)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4610 of file TypeSystemClang.cpp.

References getASTContext().

◆ GetFormat()

lldb::Format TypeSystemClang::GetFormat ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetFullyUnqualifiedType()

CompilerType TypeSystemClang::GetFullyUnqualifiedType ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetFunctionArgumentAtIndex()

CompilerType TypeSystemClang::GetFunctionArgumentAtIndex ( lldb::opaque_compiler_type_t  type,
const size_t  index 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3031 of file TypeSystemClang.cpp.

References GetQualType().

◆ GetFunctionArgumentCount()

int TypeSystemClang::GetFunctionArgumentCount ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4235 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ GetFunctionArgumentTypeAtIndex()

CompilerType TypeSystemClang::GetFunctionArgumentTypeAtIndex ( lldb::opaque_compiler_type_t  type,
size_t  idx 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4246 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ GetFunctionReturnType()

CompilerType TypeSystemClang::GetFunctionReturnType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4261 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ GetIndexForRecordBase()

uint32_t TypeSystemClang::GetIndexForRecordBase ( const clang::RecordDecl *  record_decl,
const clang::CXXBaseSpecifier *  base_spec,
bool  omit_empty_base_classes 
)

Definition at line 6535 of file TypeSystemClang.cpp.

References BaseSpecifierIsEmpty(), and UINT32_MAX.

Referenced by GetIndexOfChildMemberWithName().

◆ GetIndexForRecordChild()

uint32_t TypeSystemClang::GetIndexForRecordChild ( const clang::RecordDecl *  record_decl,
clang::NamedDecl *  canonical_decl,
bool  omit_empty_base_classes 
)

Definition at line 6563 of file TypeSystemClang.cpp.

References GetNumBaseClasses(), and UINT32_MAX.

Referenced by GetIndexOfChildMemberWithName().

◆ GetIndexOfChildMemberWithName()

size_t TypeSystemClang::GetIndexOfChildMemberWithName ( lldb::opaque_compiler_type_t  type,
llvm::StringRef  name,
bool  omit_empty_base_classes,
std::vector< uint32_t > &  child_indexes 
)
overridevirtual

◆ GetIndexOfChildWithName()

uint32_t TypeSystemClang::GetIndexOfChildWithName ( lldb::opaque_compiler_type_t  type,
llvm::StringRef  name,
bool  omit_empty_base_classes 
)
overridevirtual

◆ GetIntegralTemplateArgument()

std::optional< CompilerType::IntegralTemplateArgument > TypeSystemClang::GetIntegralTemplateArgument ( lldb::opaque_compiler_type_t  type,
size_t  idx,
bool  expand_pack 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 7242 of file TypeSystemClang.cpp.

References GetAsTemplateSpecialization(), GetNthTemplateArgument(), and GetType().

◆ GetIntTypeFromBitSize()

CompilerType TypeSystemClang::GetIntTypeFromBitSize ( size_t  bit_size,
bool  is_signed 
)

Definition at line 2327 of file TypeSystemClang.cpp.

References getASTContext(), and GetType().

Referenced by GetPointerSizedIntType().

◆ GetLangOpts()

clang::LangOptions * lldb_private::TypeSystemClang::GetLangOpts ( ) const
inline

Definition at line 1126 of file TypeSystemClang.h.

References m_language_options_up.

◆ GetLValueReferenceType()

CompilerType TypeSystemClang::GetLValueReferenceType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4483 of file TypeSystemClang.cpp.

References getASTContext(), GetQualType(), and GetType().

◆ getMangleContext()

clang::MangleContext * TypeSystemClang::getMangleContext ( )

Definition at line 709 of file TypeSystemClang.cpp.

References getASTContext(), and m_mangle_ctx_up.

Referenced by DeclGetMangledName().

◆ GetMemberFunctionAtIndex()

TypeMemberFunctionImpl TypeSystemClang::GetMemberFunctionAtIndex ( lldb::opaque_compiler_type_t  type,
size_t  idx 
)
overridevirtual

◆ GetMetadata() [1/2]

ClangASTMetadata * TypeSystemClang::GetMetadata ( const clang::Decl *  object)

◆ GetMetadata() [2/2]

ClangASTMetadata * TypeSystemClang::GetMetadata ( const clang::Type *  object)

Definition at line 2479 of file TypeSystemClang.cpp.

References m_type_metadata.

◆ GetMinimumLanguage()

lldb::LanguageType TypeSystemClang::GetMinimumLanguage ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetNativePDBParser()

npdb::PdbAstBuilder * TypeSystemClang::GetNativePDBParser ( )
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 8951 of file TypeSystemClang.cpp.

References m_native_pdb_ast_parser_up.

◆ GetNonReferenceType()

CompilerType TypeSystemClang::GetNonReferenceType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4450 of file TypeSystemClang.cpp.

References GetQualType(), and GetType().

◆ GetNumBaseClasses()

uint32_t TypeSystemClang::GetNumBaseClasses ( const clang::CXXRecordDecl *  cxx_record_decl,
bool  omit_empty_base_classes 
)

◆ GetNumberOfFunctionArguments()

size_t TypeSystemClang::GetNumberOfFunctionArguments ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3018 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ GetNumChildren()

llvm::Expected< uint32_t > TypeSystemClang::GetNumChildren ( lldb::opaque_compiler_type_t  type,
bool  omit_empty_base_classes,
const ExecutionContext exe_ctx 
)
overridevirtual

◆ GetNumDirectBaseClasses()

uint32_t TypeSystemClang::GetNumDirectBaseClasses ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetNumFields()

uint32_t TypeSystemClang::GetNumFields ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetNumMemberFunctions()

size_t TypeSystemClang::GetNumMemberFunctions ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetNumPointeeChildren()

uint32_t TypeSystemClang::GetNumPointeeChildren ( clang::QualType  type)
static

Definition at line 5951 of file TypeSystemClang.cpp.

References RemoveWrappingTypes().

Referenced by GetNumChildren().

◆ GetNumTemplateArguments()

size_t TypeSystemClang::GetNumTemplateArguments ( lldb::opaque_compiler_type_t  type,
bool  expand_pack 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 7085 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), GetCompleteType(), and RemoveWrappingTypes().

◆ GetNumVirtualBaseClasses()

uint32_t TypeSystemClang::GetNumVirtualBaseClasses ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetOpaqueCompilerType()

lldb::opaque_compiler_type_t TypeSystemClang::GetOpaqueCompilerType ( clang::ASTContext *  ast,
lldb::BasicType  basic_type 
)
static

◆ GetOrCreateClangModule()

OptionalClangModuleID TypeSystemClang::GetOrCreateClangModule ( llvm::StringRef  name,
OptionalClangModuleID  parent,
bool  is_framework = false,
bool  is_explicit = false 
)

◆ GetOrCreateStructForIdentifier()

CompilerType TypeSystemClang::GetOrCreateStructForIdentifier ( llvm::StringRef  type_name,
const std::initializer_list< std::pair< const char *, CompilerType > > &  type_fields,
bool  packed = false 
)

Definition at line 2284 of file TypeSystemClang.cpp.

References CreateStructForIdentifier().

◆ GetPDBParser()

PDBASTParser * TypeSystemClang::GetPDBParser ( )
overridevirtual

◆ GetPluginName()

llvm::StringRef lldb_private::TypeSystemClang::GetPluginName ( )
inlineoverridevirtual

Implements lldb_private::PluginInterface.

Definition at line 142 of file TypeSystemClang.h.

References GetPluginNameStatic().

◆ GetPluginNameStatic()

static llvm::StringRef lldb_private::TypeSystemClang::GetPluginNameStatic ( )
inlinestatic

Definition at line 144 of file TypeSystemClang.h.

Referenced by GetPluginName(), and Initialize().

◆ GetPointeeType()

CompilerType TypeSystemClang::GetPointeeType ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ GetPointerByteSize()

uint32_t TypeSystemClang::GetPointerByteSize ( )
overridevirtual

◆ GetPointerSizedIntType()

CompilerType TypeSystemClang::GetPointerSizedIntType ( bool  is_signed)

Definition at line 2371 of file TypeSystemClang.cpp.

References getASTContext(), and GetIntTypeFromBitSize().

◆ GetPointerType()

CompilerType TypeSystemClang::GetPointerType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4466 of file TypeSystemClang.cpp.

References getASTContext(), GetQualType(), and GetType().

Referenced by GetPointerByteSize().

◆ GetQualType()

static clang::QualType lldb_private::TypeSystemClang::GetQualType ( lldb::opaque_compiler_type_t  type)
inlinestatic

◆ GetRValueReferenceType()

CompilerType TypeSystemClang::GetRValueReferenceType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 4491 of file TypeSystemClang.cpp.

References getASTContext(), GetQualType(), and GetType().

◆ getSema()

clang::Sema * lldb_private::TypeSystemClang::getSema ( )
inline

Definition at line 172 of file TypeSystemClang.h.

References m_sema.

Referenced by lldb_private::ClangASTSource::getSema().

◆ GetSourceMgr()

clang::SourceManager * lldb_private::TypeSystemClang::GetSourceMgr ( ) const
inline

Definition at line 1129 of file TypeSystemClang.h.

References m_source_manager_up.

◆ GetStaticFieldWithName()

CompilerDecl TypeSystemClang::GetStaticFieldWithName ( lldb::opaque_compiler_type_t  type,
llvm::StringRef  name 
)
overridevirtual

◆ GetSupportedLanguagesForExpressions()

LanguageSet TypeSystemClang::GetSupportedLanguagesForExpressions ( )
static

◆ GetSupportedLanguagesForTypes()

LanguageSet TypeSystemClang::GetSupportedLanguagesForTypes ( )
static

◆ getTargetInfo()

TargetInfo * TypeSystemClang::getTargetInfo ( )

◆ getTargetOptions()

std::shared_ptr< clang::TargetOptions > & TypeSystemClang::getTargetOptions ( )

Definition at line 715 of file TypeSystemClang.cpp.

References m_target_options_rp, and m_target_triple.

Referenced by getTargetInfo().

◆ GetTargetTriple()

const char * TypeSystemClang::GetTargetTriple ( )

Definition at line 618 of file TypeSystemClang.cpp.

References m_target_triple.

Referenced by CreateASTContext().

◆ GetTemplateArgumentKind()

lldb::TemplateArgumentKind TypeSystemClang::GetTemplateArgumentKind ( lldb::opaque_compiler_type_t  type,
size_t  idx,
bool  expand_pack 
)
overridevirtual

◆ GetTranslationUnitDecl()

clang::TranslationUnitDecl * lldb_private::TypeSystemClang::GetTranslationUnitDecl ( )
inline

◆ GetType()

CompilerType lldb_private::TypeSystemClang::GetType ( clang::QualType  qt)
inline

Creates a CompilerType from the given QualType with the current TypeSystemClang instance as the CompilerType's typesystem.

Parameters
qtThe QualType for a type that belongs to the ASTContext of this TypeSystemClang.
Returns
The CompilerType representing the given QualType. If the QualType's type pointer is a nullptr then the function returns an invalid CompilerType.

Definition at line 240 of file TypeSystemClang.h.

References getASTContext().

Referenced by AddConstModifier(), lldb_private::NameSearchContext::AddGenericFunDecl(), AddRestrictModifier(), AddVolatileModifier(), lldb_private::AppleObjCTypeEncodingParser::BuildAggregate(), DWARFASTParserClang::CompleteRecordType(), CreateArrayType(), CreateBlockPointerType(), CreateClassTemplateSpecializationType(), CreateEnumerationType(), lldb_private::npdb::PdbAstBuilder::CreateFunctionParameters(), CreateFunctionType(), CreateGenericFunctionPrototype(), CreateObjCClass(), CreateRecordType(), IRForTarget::CreateResultVariable(), CreateTypedef(), DeclGetFunctionArgumentType(), DeclGetFunctionReturnType(), DumpTypeValue(), ForEachEnumerator(), GetArrayElementType(), GetArrayType(), GetAtomicType(), GetBitSize(), GetBuiltinTypeForDWARFEncodingAndBitSize(), GetBuiltinTypeForEncodingAndBitSize(), GetCanonicalType(), GetChildCompilerTypeAtIndex(), GetCStringType(), GetDirectBaseClassAtIndex(), GetDirectNestedTypeWithName(), GetEncoding(), GetEnumerationIntegerType(), GetFieldAtIndex(), GetFullyUnqualifiedType(), GetFunctionArgumentTypeAtIndex(), GetFunctionReturnType(), GetIndexOfChildMemberWithName(), GetIndexOfChildWithName(), GetIntegralTemplateArgument(), GetIntTypeFromBitSize(), GetLValueReferenceType(), GetMemberFunctionAtIndex(), GetMinimumLanguage(), GetNonReferenceType(), GetNumChildren(), GetPointeeType(), GetPointerType(), GetRValueReferenceType(), GetTypedefedType(), GetTypeForDecl(), GetTypeInfo(), GetTypeTemplateArgument(), GetVirtualBaseClassAtIndex(), lldb_private::ClangASTSource::GuardedCopyType(), IsPossibleDynamicType(), IsVectorType(), IRForTarget::MaybeHandleVariable(), lldb_private::AppleObjCTypeEncodingParser::RealizeType(), and IRForTarget::RewritePersistentAlloc().

◆ GetTypeBitAlign()

std::optional< size_t > TypeSystemClang::GetTypeBitAlign ( lldb::opaque_compiler_type_t  type,
ExecutionContextScope exe_scope 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4691 of file TypeSystemClang.cpp.

References getASTContext(), GetCompleteType(), and GetQualType().

◆ GetTypeClass()

lldb::TypeClass TypeSystemClang::GetTypeClass ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4015 of file TypeSystemClang.cpp.

References GetQualType(), and RemoveWrappingTypes().

◆ GetTypedefedType()

CompilerType TypeSystemClang::GetTypedefedType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4577 of file TypeSystemClang.cpp.

References GetQualType(), GetType(), and RemoveWrappingTypes().

◆ GetTypeForDecl() [1/5]

CompilerType TypeSystemClang::GetTypeForDecl ( clang::NamedDecl *  decl)

◆ GetTypeForDecl() [2/5]

CompilerType lldb_private::TypeSystemClang::GetTypeForDecl ( clang::ObjCInterfaceDecl *  objc_decl)

◆ GetTypeForDecl() [3/5]

CompilerType lldb_private::TypeSystemClang::GetTypeForDecl ( clang::TagDecl *  decl)

◆ GetTypeForDecl() [4/5]

CompilerType TypeSystemClang::GetTypeForDecl ( clang::ValueDecl *  value_decl)

Definition at line 1165 of file TypeSystemClang.cpp.

References GetType().

◆ GetTypeForDecl() [5/5]

CompilerType TypeSystemClang::GetTypeForDecl ( void *  opaque_decl)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 1130 of file TypeSystemClang.cpp.

References GetTypeForDecl().

◆ GetTypeForFormatters()

CompilerType TypeSystemClang::GetTypeForFormatters ( void *  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 7256 of file TypeSystemClang.cpp.

References lldb_private::ClangUtil::RemoveFastQualifiers().

◆ GetTypeForIdentifier()

template<typename RecordDeclType >
CompilerType lldb_private::TypeSystemClang::GetTypeForIdentifier ( llvm::StringRef  type_name,
clang::DeclContext *  decl_context = nullptr 
)
inline

Definition at line 259 of file TypeSystemClang.h.

References getASTContext().

Referenced by PDBASTParser::CreateLLDBTypeFromPDBType().

◆ GetTypeInfo()

uint32_t TypeSystemClang::GetTypeInfo ( lldb::opaque_compiler_type_t  type,
CompilerType pointee_or_element_compiler_type 
)
overridevirtual

◆ GetTypeName()

ConstString TypeSystemClang::GetTypeName ( lldb::opaque_compiler_type_t  type,
bool  base_only 
)
overridevirtual

◆ GetTypeNameForDecl()

std::string TypeSystemClang::GetTypeNameForDecl ( const clang::NamedDecl *  named_decl,
bool  qualified = true 
)
private

Returns the internal type name for the given NamedDecl using the type printing policy.

Definition at line 2119 of file TypeSystemClang.cpp.

References GetTypePrintingPolicy().

Referenced by DeclContextGetScopeQualifiedName(), DumpTypeDescription(), and GetTypeName().

◆ GetTypePrintingPolicy()

PrintingPolicy TypeSystemClang::GetTypePrintingPolicy ( )
private

Returns the PrintingPolicy used when generating the internal type names.

These type names are mostly used for the formatter selection.

Definition at line 2097 of file TypeSystemClang.cpp.

References getASTContext().

Referenced by DeclContextGetName(), GetTypeName(), GetTypeNameForDecl(), and PrintTemplateParams().

◆ GetTypeQualifiers()

unsigned TypeSystemClang::GetTypeQualifiers ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 4152 of file TypeSystemClang.cpp.

References GetQualType().

◆ GetTypeTemplateArgument()

CompilerType TypeSystemClang::GetTypeTemplateArgument ( lldb::opaque_compiler_type_t  type,
size_t  idx,
bool  expand_pack 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 7227 of file TypeSystemClang.cpp.

References GetAsTemplateSpecialization(), GetNthTemplateArgument(), and GetType().

◆ GetUniqueNamespaceDeclaration()

NamespaceDecl * TypeSystemClang::GetUniqueNamespaceDeclaration ( const char *  name,
clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
bool  is_inline = false 
)

◆ GetVirtualBaseClassAtIndex()

CompilerType TypeSystemClang::GetVirtualBaseClassAtIndex ( lldb::opaque_compiler_type_t  type,
size_t  idx,
uint32_t *  bit_offset_ptr 
)
overridevirtual

◆ Initialize()

void TypeSystemClang::Initialize ( )
static

◆ isA()

bool lldb_private::TypeSystemClang::isA ( const void *  ClassID) const
inlineoverridevirtual

Implements lldb_private::TypeSystem.

Reimplemented in lldb_private::ScratchTypeSystemClang.

Definition at line 117 of file TypeSystemClang.h.

References ID.

Referenced by lldb_private::ScratchTypeSystemClang::isA().

◆ IsAggregateType()

bool TypeSystemClang::IsAggregateType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2715 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and RemoveWrappingTypes().

Referenced by DumpTypeValue().

◆ IsAnonymousType()

bool TypeSystemClang::IsAnonymousType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 2736 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and RemoveWrappingTypes().

◆ IsArrayType()

bool TypeSystemClang::IsArrayType ( lldb::opaque_compiler_type_t  type,
CompilerType element_type,
uint64_t *  size,
bool *  is_incomplete 
)
overridevirtual

◆ IsBeingDefined()

bool TypeSystemClang::IsBeingDefined ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3633 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ IsBlockPointerType()

bool TypeSystemClang::IsBlockPointerType ( lldb::opaque_compiler_type_t  type,
CompilerType function_pointer_type_ptr 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3088 of file TypeSystemClang.cpp.

References IsTypeImpl(), and m_ast_up.

◆ IsCharType()

bool TypeSystemClang::IsCharType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2882 of file TypeSystemClang.cpp.

References GetQualType().

◆ IsClassType()

bool TypeSystemClang::IsClassType ( lldb::opaque_compiler_type_t  type)
static

Definition at line 3398 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ IsCompleteType()

bool TypeSystemClang::IsCompleteType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2886 of file TypeSystemClang.cpp.

References getASTContext(), GetCompleteQualType(), and GetQualType().

◆ IsConst()

bool TypeSystemClang::IsConst ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2897 of file TypeSystemClang.cpp.

References GetQualType().

◆ IsCStringType()

bool TypeSystemClang::IsCStringType ( lldb::opaque_compiler_type_t  type,
uint32_t &  length 
)

◆ IsCXXClassType()

bool TypeSystemClang::IsCXXClassType ( const CompilerType type)
static

◆ IsDefined()

bool TypeSystemClang::IsDefined ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3353 of file TypeSystemClang.cpp.

References GetQualType().

◆ IsEnumerationType()

bool TypeSystemClang::IsEnumerationType ( lldb::opaque_compiler_type_t  type,
bool &  is_signed 
)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 3129 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and IsIntegerType().

◆ IsEnumType()

bool TypeSystemClang::IsEnumType ( lldb::opaque_compiler_type_t  type)
static

Definition at line 3406 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ IsFloatingPointType()

bool TypeSystemClang::IsFloatingPointType ( lldb::opaque_compiler_type_t  type,
uint32_t &  count,
bool &  is_complex 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3315 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and IsFloatingPointType().

Referenced by IsFloatingPointType().

◆ IsForcefullyCompleted()

bool TypeSystemClang::IsForcefullyCompleted ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ IsFunctionPointerType()

bool TypeSystemClang::IsFunctionPointerType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3080 of file TypeSystemClang.cpp.

References IsTypeImpl().

◆ IsFunctionType()

bool TypeSystemClang::IsFunctionType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2926 of file TypeSystemClang.cpp.

References IsTypeImpl().

◆ IsHomogeneousAggregate()

uint32_t TypeSystemClang::IsHomogeneousAggregate ( lldb::opaque_compiler_type_t  type,
CompilerType base_type_ptr 
)
overridevirtual

◆ IsIntegerType()

bool TypeSystemClang::IsIntegerType ( lldb::opaque_compiler_type_t  type,
bool &  is_signed 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3110 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

Referenced by IsEnumerationType().

◆ IsMemberFunctionPointerType()

bool TypeSystemClang::IsMemberFunctionPointerType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3071 of file TypeSystemClang.cpp.

References IsTypeImpl().

◆ IsObjCClassType()

bool TypeSystemClang::IsObjCClassType ( const CompilerType type)
static

◆ IsObjCClassTypeAndHasIVars()

bool TypeSystemClang::IsObjCClassTypeAndHasIVars ( const CompilerType type,
bool  check_superclass 
)
static

Definition at line 8074 of file TypeSystemClang.cpp.

References GetAsObjCInterfaceDecl(), and ObjCDeclHasIVars().

◆ IsObjCObjectOrInterfaceType()

bool TypeSystemClang::IsObjCObjectOrInterfaceType ( const CompilerType type)
static

◆ IsObjCObjectPointerType()

bool TypeSystemClang::IsObjCObjectPointerType ( const CompilerType type,
CompilerType target_type = nullptr 
)
static

◆ IsOperator()

bool TypeSystemClang::IsOperator ( llvm::StringRef  name,
clang::OverloadedOperatorKind &  op_kind 
)
static

◆ IsPointerOrReferenceType()

bool TypeSystemClang::IsPointerOrReferenceType ( lldb::opaque_compiler_type_t  type,
CompilerType pointee_type 
)
overridevirtual

◆ IsPointerType()

bool TypeSystemClang::IsPointerType ( lldb::opaque_compiler_type_t  type,
CompilerType pointee_type 
)
overridevirtual

◆ IsPolymorphicClass()

bool TypeSystemClang::IsPolymorphicClass ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3414 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and GetCompleteType().

◆ IsPossibleDynamicType()

bool TypeSystemClang::IsPossibleDynamicType ( lldb::opaque_compiler_type_t  type,
CompilerType target_type,
bool  check_cplusplus,
bool  check_objc 
)
overridevirtual

◆ IsReferenceType()

bool TypeSystemClang::IsReferenceType ( lldb::opaque_compiler_type_t  type,
CompilerType pointee_type,
bool *  is_rvalue 
)
overridevirtual

◆ IsRuntimeGeneratedType()

bool TypeSystemClang::IsRuntimeGeneratedType ( lldb::opaque_compiler_type_t  type)
overridevirtual

◆ IsScalarType()

bool TypeSystemClang::IsScalarType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3577 of file TypeSystemClang.cpp.

References GetTypeInfo().

◆ IsScopedEnumerationType()

bool TypeSystemClang::IsScopedEnumerationType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3145 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ IsTemplateType()

bool TypeSystemClang::IsTemplateType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Reimplemented from lldb_private::TypeSystem.

Definition at line 7073 of file TypeSystemClang.cpp.

References lldb_private::ClangUtil::GetQualType().

◆ IsTypedefType()

bool TypeSystemClang::IsTypedefType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3584 of file TypeSystemClang.cpp.

References GetQualType(), and RemoveWrappingTypes().

◆ IsTypeImpl()

bool TypeSystemClang::IsTypeImpl ( lldb::opaque_compiler_type_t  type,
llvm::function_ref< bool(clang::QualType)>  predicate 
) const
private

◆ IsVectorType()

bool TypeSystemClang::IsVectorType ( lldb::opaque_compiler_type_t  type,
CompilerType element_type,
uint64_t *  size 
)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 2828 of file TypeSystemClang.cpp.

References GetCanonicalQualType(), and GetType().

◆ IsVoidType()

bool TypeSystemClang::IsVoidType ( lldb::opaque_compiler_type_t  type)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3591 of file TypeSystemClang.cpp.

References GetCanonicalQualType().

◆ LayoutRecordType()

bool TypeSystemClang::LayoutRecordType ( const clang::RecordDecl *  record_decl,
uint64_t &  size,
uint64_t &  alignment,
llvm::DenseMap< const clang::FieldDecl *, uint64_t > &  field_offsets,
llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &  base_offsets,
llvm::DenseMap< const clang::CXXRecordDecl *, clang::CharUnits > &  vbase_offsets 
)

◆ operator=()

const TypeSystemClang & lldb_private::TypeSystemClang::operator= ( const TypeSystemClang )
private

◆ ParseClassTemplateDecl()

clang::ClassTemplateDecl * TypeSystemClang::ParseClassTemplateDecl ( clang::DeclContext *  decl_ctx,
OptionalClangModuleID  owning_module,
lldb::AccessType  access_type,
const char *  parent_name,
int  tag_decl_kind,
const TypeSystemClang::TemplateParameterInfos template_param_infos 
)

◆ PrintTemplateParams()

std::string TypeSystemClang::PrintTemplateParams ( const TemplateParameterInfos template_param_infos)

◆ RecordHasFields()

bool TypeSystemClang::RecordHasFields ( const clang::RecordDecl *  record_decl)

◆ RequireCompleteType()

void TypeSystemClang::RequireCompleteType ( CompilerType  type)
static

◆ SetCXXRecordDeclAccess()

void TypeSystemClang::SetCXXRecordDeclAccess ( const clang::CXXRecordDecl *  object,
clang::AccessSpecifier  access 
)

◆ SetDeclIsForcefullyCompleted()

bool TypeSystemClang::SetDeclIsForcefullyCompleted ( const clang::TagDecl *  td)

◆ SetExternalSource()

void TypeSystemClang::SetExternalSource ( llvm::IntrusiveRefCntPtr< clang::ExternalASTSource > &  ast_source_up)

◆ SetFloatingInitializerForVariable()

void TypeSystemClang::SetFloatingInitializerForVariable ( clang::VarDecl *  var,
const llvm::APFloat &  init_value 
)
static

Initializes a variable with a floating point value.

Parameters
varThe variable to initialize. Must not already have an initializer and must have a floating point type.
init_valueThe float value that the variable should be initialized to.

Definition at line 7592 of file TypeSystemClang.cpp.

Referenced by PDBASTParser::AddRecordMembers().

◆ SetFunctionParameters()

void TypeSystemClang::SetFunctionParameters ( clang::FunctionDecl *  function_decl,
llvm::ArrayRef< clang::ParmVarDecl * >  params 
)

◆ SetHasExternalStorage()

bool TypeSystemClang::SetHasExternalStorage ( lldb::opaque_compiler_type_t  type,
bool  has_extern 
)
static

◆ SetIntegerInitializerForVariable()

void TypeSystemClang::SetIntegerInitializerForVariable ( clang::VarDecl *  var,
const llvm::APInt &  init_value 
)
static

Initializes a variable with an integer value.

Parameters
varThe variable to initialize. Must not already have an initializer and must have an integer or enum type.
init_valueThe integer value that the variable should be initialized to. Has to match the bit width of the variable type.

Definition at line 7567 of file TypeSystemClang.cpp.

Referenced by PDBASTParser::AddRecordMembers(), and DWARFASTParserClang::CreateStaticMemberVariable().

◆ SetIsPacked()

void TypeSystemClang::SetIsPacked ( const CompilerType type)
static

◆ SetMetadata() [1/2]

void TypeSystemClang::SetMetadata ( const clang::Decl *  object,
ClangASTMetadata meta_data 
)

◆ SetMetadata() [2/2]

void TypeSystemClang::SetMetadata ( const clang::Type *  object,
ClangASTMetadata meta_data 
)

Definition at line 2467 of file TypeSystemClang.cpp.

References m_type_metadata.

◆ SetMetadataAsUserID() [1/2]

void TypeSystemClang::SetMetadataAsUserID ( const clang::Decl *  decl,
lldb::user_id_t  user_id 
)

◆ SetMetadataAsUserID() [2/2]

void TypeSystemClang::SetMetadataAsUserID ( const clang::Type *  type,
lldb::user_id_t  user_id 
)

◆ SetObjCSuperClass()

bool TypeSystemClang::SetObjCSuperClass ( const CompilerType type,
const CompilerType superclass_compiler_type 
)
static

◆ SetOwningModule()

void TypeSystemClang::SetOwningModule ( clang::Decl *  decl,
OptionalClangModuleID  owning_module 
)
static

◆ setSema()

void TypeSystemClang::setSema ( clang::Sema *  s)

Definition at line 612 of file TypeSystemClang.cpp.

References m_ast_up, and m_sema.

◆ SetTargetTriple()

void TypeSystemClang::SetTargetTriple ( llvm::StringRef  target_triple)
private

Definition at line 622 of file TypeSystemClang.cpp.

References m_target_triple.

Referenced by TypeSystemClang().

◆ StartTagDeclarationDefinition()

bool TypeSystemClang::StartTagDeclarationDefinition ( const CompilerType type)
static

◆ SupportsLanguage()

bool TypeSystemClang::SupportsLanguage ( lldb::LanguageType  language)
overridevirtual

Implements lldb_private::TypeSystem.

Definition at line 3605 of file TypeSystemClang.cpp.

◆ Terminate()

void TypeSystemClang::Terminate ( )
static

◆ TransferBaseClasses()

bool TypeSystemClang::TransferBaseClasses ( lldb::opaque_compiler_type_t  type,
std::vector< std::unique_ptr< clang::CXXBaseSpecifier > >  bases 
)

◆ UnifyAccessSpecifiers()

clang::AccessSpecifier TypeSystemClang::UnifyAccessSpecifiers ( clang::AccessSpecifier  lhs,
clang::AccessSpecifier  rhs 
)
static

Definition at line 1727 of file TypeSystemClang.cpp.

Referenced by BuildIndirectFields().

◆ Verify()

bool TypeSystemClang::Verify ( lldb::opaque_compiler_type_t  type)
overridevirtual

Verify the integrity of the type to catch CompilerTypes that mix and match invalid TypeSystem/Opaque type pairs.

Implements lldb_private::TypeSystem.

Definition at line 2710 of file TypeSystemClang.cpp.

References GetQualType().

Member Data Documentation

◆ ID

char TypeSystemClang::ID
staticprivate

Definition at line 109 of file TypeSystemClang.h.

Referenced by classof(), and isA().

◆ m_ast_owned

bool lldb_private::TypeSystemClang::m_ast_owned = false
private

Definition at line 1180 of file TypeSystemClang.h.

Referenced by CreateASTContext(), and Finalize().

◆ m_ast_up

std::unique_ptr<clang::ASTContext> lldb_private::TypeSystemClang::m_ast_up
private

◆ m_builtins_up

std::unique_ptr<clang::Builtin::Context> lldb_private::TypeSystemClang::m_builtins_up
private

Definition at line 1172 of file TypeSystemClang.h.

Referenced by CreateASTContext(), and Finalize().

◆ m_cxx_record_decl_access

CXXRecordDeclAccessMap lldb_private::TypeSystemClang::m_cxx_record_decl_access
private

Maps CXXRecordDecl to their most recent added method/field's AccessSpecifier.

Definition at line 1198 of file TypeSystemClang.h.

Referenced by GetCXXRecordDeclAccess(), and SetCXXRecordDeclAccess().

◆ m_decl_metadata

DeclMetadataMap lldb_private::TypeSystemClang::m_decl_metadata
private

Maps Decls to their associated ClangASTMetadata.

Definition at line 1188 of file TypeSystemClang.h.

Referenced by GetMetadata(), and SetMetadata().

◆ m_diagnostic_consumer_up

std::unique_ptr<clang::DiagnosticConsumer> lldb_private::TypeSystemClang::m_diagnostic_consumer_up
private

Definition at line 1167 of file TypeSystemClang.h.

Referenced by CreateASTContext().

◆ m_diagnostics_engine_up

std::unique_ptr<clang::DiagnosticsEngine> lldb_private::TypeSystemClang::m_diagnostics_engine_up
private

Definition at line 1166 of file TypeSystemClang.h.

Referenced by CreateASTContext(), Finalize(), and GetOrCreateClangModule().

◆ m_display_name

std::string lldb_private::TypeSystemClang::m_display_name
private

A string describing what this TypeSystemClang represents (e.g., AST for debug information, an expression, some other utility ClangAST).

Useful for logging and debugging.

Definition at line 1184 of file TypeSystemClang.h.

Referenced by getDisplayName(), and TypeSystemClang().

◆ m_dwarf_ast_parser_up

std::unique_ptr<DWARFASTParserClang> lldb_private::TypeSystemClang::m_dwarf_ast_parser_up
private

Definition at line 1175 of file TypeSystemClang.h.

Referenced by GetDWARFParser(), and LayoutRecordType().

◆ m_file_manager_up

std::unique_ptr<clang::FileManager> lldb_private::TypeSystemClang::m_file_manager_up
private

Definition at line 1164 of file TypeSystemClang.h.

Referenced by CreateASTContext().

◆ m_header_search_up

std::unique_ptr<clang::HeaderSearch> lldb_private::TypeSystemClang::m_header_search_up
private

Definition at line 1173 of file TypeSystemClang.h.

Referenced by GetOrCreateClangModule().

◆ m_identifier_table_up

std::unique_ptr<clang::IdentifierTable> lldb_private::TypeSystemClang::m_identifier_table_up
private

Definition at line 1170 of file TypeSystemClang.h.

Referenced by CreateASTContext(), and Finalize().

◆ m_language_options_up

std::unique_ptr<clang::LangOptions> lldb_private::TypeSystemClang::m_language_options_up
private

◆ m_mangle_ctx_up

std::unique_ptr<clang::MangleContext> lldb_private::TypeSystemClang::m_mangle_ctx_up
private

Definition at line 1178 of file TypeSystemClang.h.

Referenced by getMangleContext().

◆ m_module_map_up

std::unique_ptr<clang::ModuleMap> lldb_private::TypeSystemClang::m_module_map_up
private

Definition at line 1174 of file TypeSystemClang.h.

Referenced by GetOrCreateClangModule().

◆ m_native_pdb_ast_parser_up

std::unique_ptr<npdb::PdbAstBuilder> lldb_private::TypeSystemClang::m_native_pdb_ast_parser_up
private

Definition at line 1177 of file TypeSystemClang.h.

Referenced by GetNativePDBParser(), and LayoutRecordType().

◆ m_pdb_ast_parser_up

std::unique_ptr<PDBASTParser> lldb_private::TypeSystemClang::m_pdb_ast_parser_up
private

Definition at line 1176 of file TypeSystemClang.h.

Referenced by GetPDBParser(), and LayoutRecordType().

◆ m_pointer_byte_size

uint32_t lldb_private::TypeSystemClang::m_pointer_byte_size = 0
private

Definition at line 1179 of file TypeSystemClang.h.

Referenced by GetPointerByteSize().

◆ m_selector_table_up

std::unique_ptr<clang::SelectorTable> lldb_private::TypeSystemClang::m_selector_table_up
private

Definition at line 1171 of file TypeSystemClang.h.

Referenced by CreateASTContext(), and Finalize().

◆ m_sema

clang::Sema* lldb_private::TypeSystemClang::m_sema = nullptr
private

The sema associated that is currently used to build this ASTContext.

May be null if we are already done parsing this ASTContext or the ASTContext wasn't created by parsing source code.

Definition at line 1203 of file TypeSystemClang.h.

Referenced by getSema(), and setSema().

◆ m_source_manager_up

std::unique_ptr<clang::SourceManager> lldb_private::TypeSystemClang::m_source_manager_up
private

◆ m_target_info_up

std::unique_ptr<clang::TargetInfo> lldb_private::TypeSystemClang::m_target_info_up
private

Definition at line 1169 of file TypeSystemClang.h.

Referenced by Finalize(), GetOrCreateClangModule(), and getTargetInfo().

◆ m_target_options_rp

std::shared_ptr<clang::TargetOptions> lldb_private::TypeSystemClang::m_target_options_rp
private

Definition at line 1168 of file TypeSystemClang.h.

Referenced by Finalize(), and getTargetOptions().

◆ m_target_triple

std::string lldb_private::TypeSystemClang::m_target_triple
private

◆ m_type_metadata

TypeMetadataMap lldb_private::TypeSystemClang::m_type_metadata
private

Maps Types to their associated ClangASTMetadata.

Definition at line 1192 of file TypeSystemClang.h.

Referenced by GetMetadata(), and SetMetadata().


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