clang 22.0.0git
|
Base wrapper for a particular "section" of type source info. More...
#include "clang/AST/TypeLoc.h"
Public Types | |
enum | TypeLocClass { Qualified } |
The kinds of TypeLocs. More... | |
Public Member Functions | |
TypeLoc ()=default | |
TypeLoc (QualType ty, void *opaqueData) | |
TypeLoc (const Type *ty, void *opaqueData) | |
template<typename T > | |
T | castAs () const |
Convert to the specified TypeLoc type, asserting that this TypeLoc is of the desired type. | |
template<typename T > | |
T | getAs () const |
Convert to the specified TypeLoc type, returning a null TypeLoc if this TypeLoc is not of the desired type. | |
template<typename T > | |
T | getAsAdjusted () const |
Convert to the specified TypeLoc type, returning a null TypeLoc if this TypeLoc is not of the desired type. | |
TypeLocClass | getTypeLocClass () const |
bool | isNull () const |
operator bool () const | |
QualType | getType () const |
Get the type for which this source info wrapper provides information. | |
const Type * | getTypePtr () const |
void * | getOpaqueData () const |
Get the pointer where source information is stored. | |
SourceLocation | getBeginLoc () const |
Get the begin source location. | |
SourceLocation | getEndLoc () const |
Get the end source location. | |
SourceRange | getSourceRange () const LLVM_READONLY |
Get the full source range. | |
SourceRange | getLocalSourceRange () const |
Get the local source range. | |
unsigned | getFullDataSize () const |
Returns the size of the type source info data block. | |
TypeLoc | getNextTypeLoc () const |
Get the next TypeLoc pointed by this TypeLoc, e.g for "int*" the TypeLoc is a PointerLoc and next TypeLoc is for "int". | |
UnqualTypeLoc | getUnqualifiedLoc () const |
Skips past any qualifiers, if this is qualified. | |
TypeLoc | IgnoreParens () const |
TypeLoc | findExplicitQualifierLoc () const |
Find a type with the location of an explicit type qualifier. | |
AutoTypeLoc | getContainedAutoTypeLoc () const |
Get the typeloc of an AutoType whose type will be deduced for a variable with an initializer of this type. | |
SourceLocation | getTemplateKeywordLoc () const |
Get the SourceLocation of the template keyword (if any). | |
NestedNameSpecifierLoc | getPrefix () const |
If this type represents a qualified-id, this returns it's nested name specifier. | |
SourceLocation | getNonPrefixBeginLoc () const |
This returns the position of the type after any elaboration, such as the 'struct' keyword, and name qualifiers. | |
SourceLocation | getNonElaboratedBeginLoc () const |
This returns the position of the type after any elaboration, such as the 'struct' keyword. | |
void | initialize (ASTContext &Context, SourceLocation Loc) const |
Initializes this to state that every location in this type is the given location. | |
void | initializeFullCopy (TypeLoc Other) |
Initializes this by copying its information from another TypeLoc of the same type. | |
void | initializeFullCopy (TypeLoc Other, unsigned Size) |
Initializes this by copying its information from another TypeLoc of the same type. | |
void | copy (TypeLoc other) |
Copies the other type loc into this one. | |
SourceLocation | findNullabilityLoc () const |
Find the location of the nullability specifier (__nonnull, __nullable, or __null_unspecifier), if there is one. | |
void | dump () const |
void | dump (llvm::raw_ostream &, const ASTContext &) const |
Static Public Member Functions | |
static unsigned | getFullDataSizeForType (QualType Ty) |
Returns the size of type source info data block for the given type. | |
static unsigned | getLocalAlignmentForType (QualType Ty) |
Returns the alignment of type source info data block for the given type. | |
Protected Attributes | |
const void * | Ty = nullptr |
void * | Data = nullptr |
Friends | |
bool | operator== (const TypeLoc &LHS, const TypeLoc &RHS) |
bool | operator!= (const TypeLoc &LHS, const TypeLoc &RHS) |
Base wrapper for a particular "section" of type source info.
A client should use the TypeLoc subclasses through castAs()/getAs() in order to get at the actual information.
The kinds of TypeLocs.
Equivalent to the Type::TypeClass enum, except it also defines a Qualified enum that corresponds to the QualifiedLoc class.
Enumerator | |
---|---|
Qualified |
|
default |
Referenced by getEndLoc(), and getLocalAlignmentForType().
|
inline |
|
inline |
Convert to the specified TypeLoc type, asserting that this TypeLoc is of the desired type.
Definition at line 78 of file TypeLoc.h.
References clang::T.
Referenced by clang::SemaObjC::actOnObjCProtocolQualifierType(), clang::SemaObjC::actOnObjCTypeArgsAndProtocolQualifiers(), clang::Sema::ActOnTemplatedFriendTag(), clang::TemplateDeclInstantiator::adjustForRewrite(), clang::Sema::BuildMemInitializer(), clang::Sema::CheckTemplateArgumentList(), clang::Sema::diagnoseQualifiedDeclaration(), clang::Sema::findInheritingConstructor(), FixInvalidVariablyModifiedTypeLoc(), getBeginLoc(), getEndLoc(), getPointee2TypeText(), clang::getPointeeTypeText(), clang::Sema::getTemplateArgumentPackExpansionPattern(), clang::ASTContext::getTemplateSpecializationTypeInfo(), GetTypeSourceInfoForDeclarator(), NeedsInstantiationAsFunctionType(), clang::TypeLocBuilder::push(), clang::TypeLocBuilder::pushTypeSpec(), clang::TemplateDeclInstantiator::SubstFunctionType(), clang::TreeTransform< Derived >::TransformFunctionTypeParam(), clang::TreeTransform< Derived >::TransformFunctionTypeParams(), and clang::TreeTransform< Derived >::TransformTypeWithDeducedTST().
void TypeLoc::copy | ( | TypeLoc | other | ) |
Copies the other type loc into this one.
Definition at line 169 of file TypeLoc.cpp.
References Data, getFullDataSize(), getNextTypeLoc(), getType(), memcpy(), and TypeLocMaxDataAlign.
Referenced by initializeFullCopy().
LLVM_DUMP_METHOD void TypeLoc::dump | ( | ) | const |
Definition at line 207 of file ASTDumper.cpp.
References clang::ASTNodeTraverser< Derived, NodeDelegateType >::Visit().
LLVM_DUMP_METHOD void TypeLoc::dump | ( | llvm::raw_ostream & | OS, |
const ASTContext & | Context | ||
) | const |
Definition at line 211 of file ASTDumper.cpp.
References clang::ASTContext::getDiagnostics(), clang::DiagnosticsEngine::getShowColors(), and clang::ASTNodeTraverser< Derived, NodeDelegateType >::Visit().
TypeLoc TypeLoc::findExplicitQualifierLoc | ( | ) | const |
Find a type with the location of an explicit type qualifier.
The result, if non-null, will be one of: QualifiedTypeLoc AtomicTypeLoc AttributedTypeLoc, for those type attributes that behave as qualifiers
Definition at line 453 of file TypeLoc.cpp.
References clang::ast_matchers::attr, getAs(), and IgnoreParens().
Referenced by clang::SemaObjC::actOnObjCTypeParam(), and clang::applyObjCTypeArgs().
SourceLocation TypeLoc::findNullabilityLoc | ( | ) | const |
Find the location of the nullability specifier (__nonnull, __nullable, or __null_unspecifier), if there is one.
Definition at line 442 of file TypeLoc.cpp.
References clang::Attr::getLocation().
Convert to the specified TypeLoc type, returning a null TypeLoc if this TypeLoc is not of the desired type.
Definition at line 89 of file TypeLoc.h.
References clang::T.
Referenced by clang::Sema::ActOnFinishFunctionBody(), clang::SemaObjC::actOnObjCTypeArgsAndProtocolQualifiers(), clang::SemaObjC::actOnObjCTypeParam(), clang::Sema::ActOnTemplateTypeArgument(), addFunctionPointerConversion(), clang::Sema::CheckEquivalentExceptionSpec(), clang::Sema::CheckFunctionDeclaration(), clang::Sema::checkThisInStaticMemberFunctionExceptionSpec(), clang::Sema::checkThisInStaticMemberFunctionType(), convertTypeTemplateArgumentToTemplate(), clang::Sema::createLambdaInitCaptureVarDecl(), DiagnoseCalleeStaticArrayParam(), findExplicitQualifierLoc(), findTypeLocationForBlockDecl(), FixInvalidVariablyModifiedTypeLoc(), getAsAdjusted(), getContainedAutoTypeLoc(), clang::FunctionDecl::getFunctionTypeLoc(), clang::comments::getFunctionTypeLoc(), GetTypeSourceInfoForDeclarator(), isEnableIf(), clang::Decl::isFlexibleArrayMemberLike(), clang::comments::lookThroughTypedefOrTypeAliasLocs(), NeedsInstantiationAsFunctionType(), clang::Sema::SubstFunctionDeclType(), clang::TemplateDeclInstantiator::SubstFunctionType(), clang::Sema::SubstParmVarDecl(), clang::TreeTransform< Derived >::TransformNestedNameSpecifierLoc(), and clang::TreeTransform< Derived >::TransformTypeWithDeducedTST().
Convert to the specified TypeLoc type, returning a null TypeLoc if this TypeLoc is not of the desired type.
It will consider type adjustments from a type that was written as a T to another type that is still canonically a T (ignores parens, attributes, elaborated types, etc).
Definition at line 2843 of file TypeLoc.h.
References getAs(), and clang::T.
Referenced by clang::Sema::ActOnBlockArguments(), clang::TemplateDeclInstantiator::adjustForRewrite(), clang::Sema::CheckDeductionGuideDeclarator(), checkLifetimeBoundAttr(), clang::Sema::checkLifetimeCaptureBy(), findTypeLocationForBlockDecl(), clang::Sema::getReturnTypeLoc(), clang::sema::implicitObjectParamIsLifetimeBound(), clang::Decl::isFlexibleArrayMemberLike(), clang::Sema::LazyProcessLifetimeCaptureByParams(), and clang::TreeTransform< Derived >::TransformNestedNameSpecifierLoc().
SourceLocation TypeLoc::getBeginLoc | ( | ) | const |
Get the begin source location.
Definition at line 193 of file TypeLoc.cpp.
References castAs(), clang::SourceRange::getBegin(), getLocalSourceRange(), getNextTypeLoc(), getTypeLocClass(), clang::InheritingConcreteTypeLoc< Base, Derived, TypeClass >::getTypePtr(), clang::FunctionProtoType::hasTrailingReturn(), isNull(), clang::SourceLocation::isValid(), and Qualified.
Referenced by clang::Sema::ActOnAliasDeclaration(), clang::Sema::ActOnCXXTypeConstructExpr(), clang::Sema::ActOnFriendTypeDecl(), clang::SemaObjC::ActOnMethodParmDeclaration(), clang::SemaObjC::actOnObjCTypeParam(), clang::SemaOpenMP::ActOnOMPIteratorExpr(), clang::Sema::ActOnTag(), clang::Sema::ActOnTemplateTypeArgument(), clang::Sema::ActOnVariableDeclarator(), clang::applyObjCTypeArgs(), clang::Sema::AttachTypeConstraint(), clang::Sema::BuildBaseInitializer(), clang::Sema::BuildBuiltinBitCastExpr(), clang::Sema::BuildCXXTypeConstructExpr(), clang::Sema::BuildPseudoDestructorExpr(), clang::Sema::BuildVAArgExpr(), clang::Sema::CheckBaseSpecifier(), CheckConstexprDeclStmt(), CheckConvertibilityForTypeTraits(), clang::Sema::CheckDeductionGuideDeclarator(), clang::Sema::CheckEnumUnderlyingType(), clang::SemaObjC::CreatePropertyDecl(), clang::Sema::DeduceTemplateSpecializationFromInitializer(), clang::Sema::deduceVarTypeFromInitializer(), EvaluateBinaryTypeTrait(), EvaluateUnaryTypeTrait(), clang::CXXBaseSpecifier::getBaseTypeLoc(), clang::CXXFunctionalCastExpr::getBeginLoc(), clang::CXXTemporaryObjectExpr::getBeginLoc(), GetFullTypeForDeclarator(), clang::NestedNameSpecifierLoc::getLocalSourceRange(), clang::DependentNameTypeLoc::getLocalSourceRange(), clang::DependentTemplateSpecializationTypeLoc::getLocalSourceRange(), getNonElaboratedBeginLoc(), getNonPrefixBeginLoc(), getPointee2TypeText(), clang::getPointeeTypeText(), getSourceRange(), clang::DeclaratorDecl::getTypeSpecStartLoc(), handleAlignedAttr(), handlePreferredTypeAttr(), clang::SemaHLSL::handleResourceTypeAttr(), clang::ASTImporter::Import(), clang::Sema::InstantiateFunctionDefinition(), clang::Sema::IsPointerInterconvertibleBaseOf(), clang::CXXScopeSpec::Make(), clang::PseudoDestructorTypeStorage::PseudoDestructorTypeStorage(), clang::TreeTransform< Derived >::RebuildQualifiedType(), clang::TreeTransform< Derived >::TransformFunctionProtoType(), clang::TreeTransform< Derived >::TransformNestedNameSpecifierLoc(), clang::TreeTransform< Derived >::TransformType(), and clang::TreeTransform< Derived >::TransformTypeWithDeducedTST().
AutoTypeLoc TypeLoc::getContainedAutoTypeLoc | ( | ) | const |
Get the typeloc of an AutoType whose type will be deduced for a variable with an initializer of this type.
This looks through declarators like pointer types, but not through decltype or typedefs.
Definition at line 942 of file TypeLoc.cpp.
References getAs(), and isNull().
Referenced by clang::Sema::ActOnNonTypeTemplateParameter(), clang::Sema::ActOnTypeName(), clang::Sema::ActOnVariableDeclarator(), and InventTemplateParameter().
SourceLocation TypeLoc::getEndLoc | ( | ) | const |
Get the end source location.
Definition at line 227 of file TypeLoc.cpp.
References castAs(), getNextTypeLoc(), clang::ObjCObjectPointerTypeLoc::getStarLoc(), getTypeLocClass(), clang::InheritingConcreteTypeLoc< Base, Derived, TypeClass >::getTypePtr(), clang::FunctionProtoType::hasTrailingReturn(), clang::SourceLocation::isInvalid(), clang::Last, Paren, Pointer, Qualified, and TypeLoc().
Referenced by clang::SemaObjC::actOnObjCTypeParam(), clang::SemaObjC::ActOnSuperClassOfClassInterface(), clang::Sema::BuildBuiltinBitCastExpr(), clang::Sema::CheckConversionDeclarator(), clang::Sema::CheckParameter(), clang::SemaObjC::CreatePropertyDecl(), clang::Sema::DeduceTemplateSpecializationFromInitializer(), GetFullTypeForDeclarator(), getPointee2TypeText(), clang::getPointeeTypeText(), getSourceRange(), and clang::DeclaratorDecl::getTypeSpecEndLoc().
|
inline |
Returns the size of the type source info data block.
Definition at line 165 of file TypeLoc.h.
References getFullDataSizeForType(), and getType().
Referenced by clang::AutoTypeLoc::copy(), clang::DependentNameTypeLoc::copy(), clang::DependentTemplateSpecializationTypeLoc::copy(), clang::TemplateSpecializationTypeLoc::copy(), copy(), GetTypeSourceInfoForDeclarator(), initializeFullCopy(), clang::TypeLocBuilder::pushFullCopy(), clang::Sema::SubstFunctionDeclType(), clang::Sema::SubstType(), clang::TreeTransform< Derived >::TransformFunctionTypeParam(), clang::TreeTransform< Derived >::TransformType(), and clang::TreeTransform< Derived >::TransformTypeWithDeducedTST().
Returns the size of type source info data block for the given type.
Returns the size of the type source info data block.
Definition at line 95 of file TypeLoc.cpp.
References getLocalAlignmentForType(), getNextTypeLoc(), getType(), isNull(), and Ty.
Referenced by clang::ASTContext::adjustExceptionSpec(), clang::ASTContext::CreateTypeSourceInfo(), and getFullDataSize().
Returns the alignment of type source info data block for the given type.
Returns the alignment of the type source info data block.
Definition at line 75 of file TypeLoc.cpp.
Referenced by getFullDataSizeForType(), and clang::QualifiedTypeLoc::getUnqualifiedLoc().
|
inline |
Get the local source range.
Definition at line 160 of file TypeLoc.h.
Referenced by clang::Sema::BuildBaseInitializer(), clang::Sema::BuildBuiltinOffsetOf(), CheckDeducedPlaceholderConstraints(), getBeginLoc(), and clang::MacroQualifiedTypeLoc::getLocalSourceRange().
|
inline |
Get the next TypeLoc pointed by this TypeLoc, e.g for "int*" the TypeLoc is a PointerLoc and next TypeLoc is for "int".
Definition at line 171 of file TypeLoc.h.
Referenced by clang::ASTRecordWriter::AddTypeLoc(), copy(), getBeginLoc(), getEndLoc(), getFullDataSizeForType(), clang::getPointeeTypeText(), GetTypeSourceInfoForDeclarator(), clang::TypeLocBuilder::pushFullCopy(), and clang::ASTRecordReader::readTypeLoc().
SourceLocation TypeLoc::getNonElaboratedBeginLoc | ( | ) | const |
This returns the position of the type after any elaboration, such as the 'struct' keyword.
This may be the position of the name qualifiers, 'template' keyword, or the name location otherwise.
Definition at line 539 of file TypeLoc.cpp.
References getBeginLoc(), getTypeLocClass(), Qualified, and clang::T.
SourceLocation TypeLoc::getNonPrefixBeginLoc | ( | ) | const |
This returns the position of the type after any elaboration, such as the 'struct' keyword, and name qualifiers.
This will the 'template' keyword if present, or the name location otherwise.
Definition at line 499 of file TypeLoc.cpp.
References getBeginLoc(), getTemplateKeywordLoc(), getTypeLocClass(), clang::SourceLocation::isValid(), and Loc.
|
inline |
Get the pointer where source information is stored.
Definition at line 143 of file TypeLoc.h.
References Data.
Referenced by clang::TypeLocBuilder::getTypeSourceInfo(), GetTypeSourceInfoForDeclarator(), and clang::NestedNameSpecifierLocBuilder::Make().
NestedNameSpecifierLoc TypeLoc::getPrefix | ( | ) | const |
If this type represents a qualified-id, this returns it's nested name specifier.
For example, for the qualified-id "foo::bar::baz", this returns "foo::bar". Returns null if this type represents an unqualified-id.
Definition at line 474 of file TypeLoc.cpp.
References getTypeLocClass().
Referenced by clang::UsingEnumDecl::getQualifierLoc(), and clang::RecursiveASTVisitor< Derived >::TraverseNestedNameSpecifierLoc().
|
inline |
Get the full source range.
Definition at line 154 of file TypeLoc.h.
References getBeginLoc(), and getEndLoc().
Referenced by clang::Sema::ActOnConversionDeclarator(), clang::Sema::ActOnFriendTypeDecl(), clang::SemaObjC::actOnObjCTypeArgsAndProtocolQualifiers(), clang::Sema::ActOnVariableDeclarator(), clang::Sema::AddAlignedAttr(), clang::SemaObjC::AdjustParameterTypeForObjCAutoRefCount(), AnalyzeBitFieldAssignment(), clang::applyObjCTypeArgs(), clang::Sema::AttachTypeConstraint(), clang::Sema::BuildBaseInitializer(), clang::SemaObjC::BuildClassMessage(), clang::Sema::BuildCStyleCastExpr(), clang::Sema::BuildCXXFunctionalCastExpr(), clang::Sema::BuildCXXNew(), clang::Sema::BuildDelegatingInitializer(), clang::SemaObjC::BuildObjCBridgedCast(), clang::Sema::BuildPseudoDestructorExpr(), clang::Sema::BuildVAArgExpr(), clang::Sema::CheckBaseSpecifier(), CheckConstexprDeclStmt(), clang::Sema::CheckConversionDeclarator(), clang::Sema::CheckDeductionGuideDeclarator(), clang::Sema::CheckPackExpansion(), clang::Sema::CheckParameter(), clang::Sema::CheckTemplateArgument(), checkTypeParamListConsistency(), clang::Sema::CreateGenericSelectionExpr(), clang::Sema::DeduceTemplateSpecializationFromInitializer(), findTemplateParameter(), getPointee2TypeText(), clang::getPointeeTypeText(), clang::Sema::getPrintable(), getRangeOfTypeInNestedNameSpecifier(), clang::ObjCMessageExpr::getReceiverRange(), clang::FunctionDecl::getReturnTypeSourceRange(), getTypeRange(), clang::Sema::InstantiateMemInitializers(), clang::TreeTransform< Derived >::TransformFunctionTypeParam(), clang::JSONNodeDumper::Visit(), and clang::TextNodeDumper::Visit().
SourceLocation TypeLoc::getTemplateKeywordLoc | ( | ) | const |
Get the SourceLocation of the template keyword (if any).
Definition at line 949 of file TypeLoc.cpp.
Referenced by getNonPrefixBeginLoc().
|
inline |
Get the type for which this source info wrapper provides information.
Definition at line 133 of file TypeLoc.h.
References clang::QualType::getFromOpaquePtr(), and Ty.
Referenced by clang::ASTRecordWriter::AddNestedNameSpecifierLoc(), AddObjCBlockCall(), clang::Sema::AttachTypeConstraint(), CheckConstexprDeclStmt(), copy(), clang::Sema::DeduceFunctionTypeFromReturnExpr(), clang::comments::DeclInfo::fill(), findTemplateParameter(), getFullDataSize(), getFullDataSizeForType(), clang::Sema::getTemplateArgumentPackExpansionPattern(), getTypeLocClass(), initializeFullCopy(), clang::TreeTransform< Derived >::RebuildQualifiedType(), clang::Sema::SubstType(), clang::TreeTransform< Derived >::TransformFunctionProtoType(), clang::TreeTransform< Derived >::TransformNestedNameSpecifierLoc(), clang::TreeTransform< Derived >::TransformTagType(), clang::JSONNodeDumper::Visit(), clang::TextNodeDumper::Visit(), and clang::ASTNodeTraverser< Derived, NodeDelegateType >::VisitDependentSizedExtVectorTypeLoc().
|
inline |
Definition at line 116 of file TypeLoc.h.
References getType(), clang::Type::getTypeClass(), and Qualified.
Referenced by getBeginLoc(), getEndLoc(), getNonElaboratedBeginLoc(), getNonPrefixBeginLoc(), getPointee2TypeText(), clang::getPointeeTypeText(), getPrefix(), clang::TypeLocBuilder::pushFullCopy(), clang::RecursiveASTVisitor< Derived >::TraverseTypeLoc(), clang::JSONNodeDumper::Visit(), clang::TypeLocVisitor< ImplClass, RetTy >::Visit(), and clang::TextNodeDumper::Visit().
|
inline |
Definition at line 137 of file TypeLoc.h.
References clang::QualType::getFromOpaquePtr(), clang::QualType::getTypePtr(), and Ty.
Referenced by clang::QualifiedTypeLoc::getUnqualifiedLoc(), clang::NestedNameSpecifierLocBuilder::Make(), clang::JSONNodeDumper::Visit(), and clang::TextNodeDumper::VisitTypeLoc().
|
inline |
Skips past any qualifiers, if this is qualified.
Definition at line 354 of file TypeLoc.h.
References Loc.
Referenced by clang::comments::DeclInfo::fill(), findTypeLocationForBlockDecl(), FixInvalidVariablyModifiedTypeLoc(), clang::comments::getFunctionTypeLoc(), getPointee2TypeText(), clang::getPointeeTypeText(), GetTypeSourceInfoForDeclarator(), clang::comments::lookThroughTypedefOrTypeAliasLocs(), clang::TreeTransform< Derived >::TransformTypeWithDeducedTST(), and clang::RecursiveASTVisitor< Derived >::WalkUpFromUnqualTypeLoc().
|
inline |
Definition at line 1417 of file TypeLoc.h.
Referenced by clang::Sema::CheckEquivalentExceptionSpec(), clang::Sema::CheckFunctionDeclaration(), findExplicitQualifierLoc(), clang::Sema::findInheritingConstructor(), findTypeLocationForBlockDecl(), clang::comments::lookThroughTypedefOrTypeAliasLocs(), clang::Sema::SubstFunctionDeclType(), and clang::TemplateDeclInstantiator::SubstFunctionType().
|
inline |
Initializes this to state that every location in this type is the given location.
This method exists to provide a simple transition for code that relies on location-less types.
Definition at line 216 of file TypeLoc.h.
References Loc.
Referenced by clang::ASTContext::getTrivialTypeSourceInfo().
|
inline |
Initializes this by copying its information from another TypeLoc of the same type.
Definition at line 222 of file TypeLoc.h.
References copy(), getType(), and clang::Other.
Referenced by clang::Sema::ActOnBlockArguments(), and FixInvalidVariablyModifiedTypeLoc().
Initializes this by copying its information from another TypeLoc of the same type.
The given size must be the full data size.
Definition at line 230 of file TypeLoc.h.
References copy(), getFullDataSize(), getType(), and clang::Other.
|
inline |
Definition at line 121 of file TypeLoc.h.
References Ty.
Referenced by clang::ASTRecordWriter::AddTypeLoc(), clang::Sema::BuildMemInitializer(), getBeginLoc(), getContainedAutoTypeLoc(), getFullDataSizeForType(), getPointee2TypeText(), clang::getPointeeTypeText(), clang::index::IndexingContext::indexTypeLoc(), clang::index::IndexingContext::indexTypeSourceInfo(), clang::transformer::name(), clang::ASTRecordReader::readTypeLoc(), clang::RecursiveASTVisitor< Derived >::TraverseTypeLoc(), and clang::JSONNodeDumper::Visit().
|
inlineexplicit |
|
protected |
Definition at line 64 of file TypeLoc.h.
Referenced by copy(), getOpaqueData(), and clang::QualifiedTypeLoc::getUnqualifiedLoc().
|
protected |
Definition at line 63 of file TypeLoc.h.
Referenced by getFullDataSizeForType(), getLocalAlignmentForType(), getType(), getTypePtr(), clang::UnqualTypeLoc::getTypePtr(), isNull(), and operator bool().