clang: clang::DeclarationNameInfo Struct Reference (original) (raw)
DeclarationNameInfo - A collector data type for bundling together a DeclarationName and the corresponding source/type location info. More...
#include "[clang/AST/DeclarationName.h](DeclarationName%5F8h%5Fsource.html)"
Public Member Functions | |
---|---|
DeclarationNameInfo ()=default | |
DeclarationNameInfo (DeclarationName Name, SourceLocation NameLoc) | |
DeclarationNameInfo (DeclarationName Name, SourceLocation NameLoc, DeclarationNameLoc LocInfo) | |
DeclarationName | getName () const |
getName - Returns the embedded declaration name. | |
void | setName (DeclarationName N) |
setName - Sets the embedded declaration name. | |
SourceLocation | getLoc () const |
getLoc - Returns the main location of the declaration name. | |
void | setLoc (SourceLocation L) |
setLoc - Sets the main location of the declaration name. | |
const DeclarationNameLoc & | getInfo () const |
void | setInfo (const DeclarationNameLoc &Info) |
TypeSourceInfo * | getNamedTypeInfo () const |
getNamedTypeInfo - Returns the source type info associated to the name. | |
void | setNamedTypeInfo (TypeSourceInfo *TInfo) |
setNamedTypeInfo - Sets the source type info associated to the name. | |
SourceRange | getCXXOperatorNameRange () const |
getCXXOperatorNameRange - Gets the range of the operator name (without the operator keyword). | |
void | setCXXOperatorNameRange (SourceRange R) |
setCXXOperatorNameRange - Sets the range of the operator name (without the operator keyword). | |
SourceLocation | getCXXLiteralOperatorNameLoc () const |
getCXXLiteralOperatorNameLoc - Returns the location of the literal operator name (not the operator keyword). | |
void | setCXXLiteralOperatorNameLoc (SourceLocation Loc) |
setCXXLiteralOperatorNameLoc - Sets the location of the literal operator name (not the operator keyword). | |
bool | isInstantiationDependent () const |
Determine whether this name involves a template parameter. | |
bool | containsUnexpandedParameterPack () const |
Determine whether this name contains an unexpanded parameter pack. | |
std::string | getAsString () const |
getAsString - Retrieve the human-readable string for this name. | |
void | printName (raw_ostream &OS, PrintingPolicy Policy) const |
printName - Print the human-readable name to a stream. | |
SourceLocation | getBeginLoc () const |
getBeginLoc - Retrieve the location of the first token. | |
SourceRange | getSourceRange () const LLVM_READONLY |
getSourceRange - The range of the declaration name. | |
SourceLocation | getEndLoc () const LLVM_READONLY |
DeclarationNameInfo - A collector data type for bundling together a DeclarationName and the corresponding source/type location info.
Definition at line 768 of file DeclarationName.h.
clang::DeclarationNameInfo::DeclarationNameInfo ( ) | default |
---|
◆ DeclarationNameInfo() [2/3]
◆ DeclarationNameInfo() [3/3]
◆ containsUnexpandedParameterPack()
bool DeclarationNameInfo::containsUnexpandedParameterPack | ( | ) | const |
---|
Determine whether this name contains an unexpanded parameter pack.
Definition at line 405 of file DeclarationName.cpp.
References clang::Type::containsUnexpandedParameterPack(), clang::DeclarationName::CXXConstructorName, clang::DeclarationName::CXXConversionFunctionName, clang::DeclarationName::CXXDeductionGuideName, clang::DeclarationName::CXXDestructorName, clang::DeclarationName::CXXLiteralOperatorName, clang::DeclarationName::CXXOperatorName, clang::DeclarationName::CXXUsingDirective, clang::DeclarationName::getCXXNameType(), clang::DeclarationNameLoc::getNamedTypeInfo(), clang::DeclarationName::getNameKind(), clang::DeclarationName::Identifier, clang::DeclarationName::ObjCMultiArgSelector, clang::DeclarationName::ObjCOneArgSelector, and clang::DeclarationName::ObjCZeroArgSelector.
Referenced by clang::Sema::ActOnUsingDeclaration().
◆ getAsString()
std::string DeclarationNameInfo::getAsString | ( | ) | const |
---|
◆ getBeginLoc()
SourceLocation clang::DeclarationNameInfo::getBeginLoc ( ) const | inline |
---|
getBeginLoc - Retrieve the location of the first token.
Definition at line 870 of file DeclarationName.h.
Referenced by clang::Sema::ActOnFriendFunctionDecl(), actOnOMPReductionKindClause(), clang::Sema::BuildDeclarationNameExpr(), clang::Sema::CheckPlaceholderExpr(), clang::Sema::diagnoseExprIntendedAsTemplateName(), clang::ConceptReference::getBeginLoc(), clang::DeclRefExpr::getBeginLoc(), clang::UnresolvedLookupExpr::getBeginLoc(), clang::CXXDependentScopeMemberExpr::getBeginLoc(), clang::UnresolvedMemberExpr::getBeginLoc(), getFunNameText(), and clang::FunctionDecl::getReturnTypeSourceRange().
◆ getCXXLiteralOperatorNameLoc()
SourceLocation clang::DeclarationNameInfo::getCXXLiteralOperatorNameLoc ( ) const | inline |
---|
◆ getCXXOperatorNameRange()
SourceRange clang::DeclarationNameInfo::getCXXOperatorNameRange ( ) const | inline |
---|
◆ getEndLoc()
Definition at line 877 of file DeclarationName.h.
References clang::SourceLocation::isValid().
Referenced by actOnOMPReductionKindClause(), clang::Sema::ActOnUsingDeclaration(), clang::Sema::BuildDeclarationNameExpr(), clang::Sema::BuildDependentDeclRefExpr(), clang::Sema::BuildQualifiedDeclarationNameExpr(), clang::Sema::CheckPlaceholderExpr(), clang::Sema::CheckUsingDeclQualifier(), clang::ConceptReference::getEndLoc(), clang::DeclRefExpr::getEndLoc(), clang::MemberExpr::getEndLoc(), clang::UnresolvedLookupExpr::getEndLoc(), clang::CXXDependentScopeMemberExpr::getEndLoc(), clang::UnresolvedMemberExpr::getEndLoc(), and getFunNameText().
◆ getInfo()
◆ getLoc()
getLoc - Returns the main location of the declaration name.
Definition at line 797 of file DeclarationName.h.
Referenced by clang::Sema::ActOnCXXMemberDeclarator(), clang::Sema::ActOnIdExpression(), actOnOMPReductionKindClause(), clang::ASTRecordWriter::AddDeclarationNameInfo(), clang::Sema::BuildCallToObjectOfClassType(), clang::Sema::BuildDeclarationNameExpr(), clang::Sema::BuildDeclRefExpr(), clang::Sema::BuildFieldReferenceExpr(), clang::Sema::BuildLiteralOperatorCall(), clang::Sema::BuildMemberExpr(), clang::Sema::BuildMemberReferenceExpr(), BuildMSPropertyRefExpr(), clang::Sema::BuildQualifiedDeclarationNameExpr(), clang::Sema::BuildQualifiedTemplateIdExpr(), buildUserDefinedMapperRef(), clang::Sema::BuildUsingDeclaration(), clang::Sema::CheckConceptTemplateId(), clang::Sema::CheckPlaceholderExpr(), clang::Sema::CheckTemplateTypeArgument(), clang::Sema::CheckVarTemplateId(), clang::Sema::CorrectTypo(), clang::Sema::CorrectTypoDelayed(), clang::Sema::CreateOverloadedArraySubscriptExpr(), clang::Sema::DiagnoseClassNameShadow(), clang::Sema::diagnoseExprIntendedAsTemplateName(), diagnoseInstanceReference(), DiagnoseQualifiedMemberReference(), clang::Sema::DiagnoseUnexpandedParameterPack(), clang::ConceptReference::getConceptNameLoc(), clang::DependentScopeDeclRefExpr::getLocation(), clang::CXXDependentScopeMemberExpr::getMemberLoc(), clang::OverloadExpr::getNameLoc(), clang::LookupResult::getNameLoc(), hasUserDefinedMapper(), clang::ASTNodeImporter::import(), recoverFromMSUnqualifiedLookup(), clang::Sema::SubstDeclarationNameInfo(), and clang::TreeTransform< Derived >::TransformDeclarationNameInfo().
◆ getName()
getName - Returns the embedded declaration name.
Definition at line 791 of file DeclarationName.h.
Referenced by clang::Sema::ActOnCXXMemberDeclarator(), clang::Sema::ActOnDependentMemberExpr(), clang::Sema::ActOnExplicitInstantiation(), clang::Sema::ActOnFriendFunctionDecl(), clang::Sema::ActOnFunctionDeclarator(), clang::Sema::ActOnIdExpression(), actOnOMPReductionKindClause(), clang::SemaOpenMP::ActOnOpenMPCriticalDirective(), clang::Sema::ActOnTemplateName(), clang::Sema::ActOnUsingDeclaration(), clang::Sema::ActOnVariableDeclarator(), clang::ASTRecordWriter::AddDeclarationNameInfo(), buildMemberCall(), clang::Sema::BuildMemberReferenceExpr(), clang::Sema::BuildPossibleImplicitMemberExpr(), clang::Sema::BuildQualifiedDeclarationNameExpr(), clang::Sema::BuildQualifiedTemplateIdExpr(), buildUserDefinedMapperRef(), clang::Sema::BuildUsingDeclaration(), clang::Sema::CheckFunctionOrTemplateParamDeclarator(), clang::Sema::CheckMicrosoftIfExistsSymbol(), checkNestingOfRegions(), clang::Sema::CheckPlaceholderExpr(), clang::Sema::CheckTemplateTypeArgument(), clang::Sema::CheckUsingDeclQualifier(), clang::Sema::ClassifyName(), clang::Sema::CorrectTypo(), clang::Sema::CorrectTypoDelayed(), clang::CXXDestructorDecl::Create(), clang::CXXConversionDecl::Create(), clang::CXXConstructorDecl::Create(), CreateNewFunctionDecl(), clang::Sema::DiagnoseClassNameShadow(), clang::Sema::diagnoseExprIntendedAsTemplateName(), diagnoseInstanceReference(), clang::Sema::DiagnoseUnexpandedParameterPack(), clang::Sema::FindInstantiatedDecl(), clang::DependentScopeDeclRefExpr::getDeclName(), clang::LookupResult::getLookupName(), clang::CXXDependentScopeMemberExpr::getMember(), clang::OverloadExpr::getName(), handleCleanupAttr(), clang::Sema::HandleDeclarator(), clang::ASTNodeImporter::import(), clang::ASTNodeImporter::ImportDeclarationNameLoc(), clang::ASTRecordReader::readDeclarationNameInfo(), recoverFromMSUnqualifiedLookup(), clang::Sema::SubstDeclarationNameInfo(), clang::TreeTransform< Derived >::TransformDeclarationNameInfo(), clang::transformOMPMappableExprListClause(), and clang::RecursiveASTVisitor< Derived >::TraverseDeclarationNameInfo().
◆ getNamedTypeInfo()
TypeSourceInfo * clang::DeclarationNameInfo::getNamedTypeInfo ( ) const | inline |
---|
◆ getSourceRange()
SourceRange clang::DeclarationNameInfo::getSourceRange ( ) const | inline |
---|
◆ isInstantiationDependent()
bool DeclarationNameInfo::isInstantiationDependent | ( | ) | const |
---|
Determine whether this name involves a template parameter.
Definition at line 428 of file DeclarationName.cpp.
References clang::DeclarationName::CXXConstructorName, clang::DeclarationName::CXXConversionFunctionName, clang::DeclarationName::CXXDeductionGuideName, clang::DeclarationName::CXXDestructorName, clang::DeclarationName::CXXLiteralOperatorName, clang::DeclarationName::CXXOperatorName, clang::DeclarationName::CXXUsingDirective, clang::DeclarationName::getCXXNameType(), clang::DeclarationNameLoc::getNamedTypeInfo(), clang::DeclarationName::getNameKind(), clang::DeclarationName::Identifier, clang::Type::isInstantiationDependentType(), clang::DeclarationName::ObjCMultiArgSelector, clang::DeclarationName::ObjCOneArgSelector, and clang::DeclarationName::ObjCZeroArgSelector.
◆ printName()
void DeclarationNameInfo::printName | ( | raw_ostream & | OS, |
---|---|---|---|
PrintingPolicy | Policy | ||
) | const |
printName - Print the human-readable name to a stream.
Definition at line 464 of file DeclarationName.cpp.
References clang::PrintingPolicy::adjustForCPlusPlus(), clang::DeclarationName::CXXConstructorName, clang::DeclarationName::CXXConversionFunctionName, clang::DeclarationName::CXXDeductionGuideName, clang::DeclarationName::CXXDestructorName, clang::DeclarationName::CXXLiteralOperatorName, clang::DeclarationName::CXXOperatorName, clang::DeclarationName::CXXUsingDirective, clang::DeclarationNameLoc::getNamedTypeInfo(), clang::DeclarationName::getNameKind(), clang::DeclarationName::Identifier, clang::DeclarationName::ObjCMultiArgSelector, clang::DeclarationName::ObjCOneArgSelector, clang::DeclarationName::ObjCZeroArgSelector, clang::DeclarationName::print(), and clang::PrintingPolicy::SuppressScope.
Referenced by clang::operator<<(), and clang::ConceptReference::print().
◆ setCXXLiteralOperatorNameLoc()
void clang::DeclarationNameInfo::setCXXLiteralOperatorNameLoc ( SourceLocation Loc) | inline |
---|
◆ setCXXOperatorNameRange()
void clang::DeclarationNameInfo::setCXXOperatorNameRange ( SourceRange R) | inline |
---|
◆ setInfo()
◆ setLoc()
◆ setName()
◆ setNamedTypeInfo()
void clang::DeclarationNameInfo::setNamedTypeInfo ( TypeSourceInfo * TInfo) | inline |
---|
The documentation for this struct was generated from the following files:
- include/clang/AST/DeclarationName.h
- lib/AST/DeclarationName.cpp