|
clang
3.8.0
|
Stores a list of template parameters for a TemplateDecl and its derived classes. More...
#include <DeclTemplate.h>
Public Types | |
| typedef NamedDecl ** | iterator |
| Iterates through the template parameters in this list. More... | |
| typedef NamedDecl *const * | const_iterator |
| Iterates through the template parameters in this list. More... | |
Public Member Functions | |
| iterator | begin () |
| const_iterator | begin () const |
| iterator | end () |
| const_iterator | end () const |
| unsigned | size () const |
| ArrayRef< NamedDecl * > | asArray () |
| ArrayRef< const NamedDecl * > | asArray () const |
| NamedDecl * | getParam (unsigned Idx) |
| const NamedDecl * | getParam (unsigned Idx) const |
| unsigned | getMinRequiredArguments () const |
| Returns the minimum number of arguments needed to form a template specialization. More... | |
| unsigned | getDepth () const |
| Get the depth of this template parameter list in the set of template parameter lists. More... | |
| bool | containsUnexpandedParameterPack () const |
| Determine whether this template parameter list contains an unexpanded parameter pack. More... | |
| SourceLocation | getTemplateLoc () const |
| SourceLocation | getLAngleLoc () const |
| SourceLocation | getRAngleLoc () const |
| SourceRange | getSourceRange () const LLVM_READONLY |
Static Public Member Functions | |
| static TemplateParameterList * | Create (const ASTContext &C, SourceLocation TemplateLoc, SourceLocation LAngleLoc, ArrayRef< NamedDecl * > Params, SourceLocation RAngleLoc) |
Public Attributes | |
| friend | TrailingObjects |
Protected Member Functions | |
| size_t | numTrailingObjects (OverloadToken< NamedDecl * >) const |
| TemplateParameterList (SourceLocation TemplateLoc, SourceLocation LAngleLoc, ArrayRef< NamedDecl * > Params, SourceLocation RAngleLoc) | |
Friends | |
| template<size_t N> | |
| class | FixedSizeTemplateParameterListStorage |
Stores a list of template parameters for a TemplateDecl and its derived classes.
Definition at line 48 of file DeclTemplate.h.
| typedef NamedDecl* const* clang::TemplateParameterList::const_iterator |
Iterates through the template parameters in this list.
Definition at line 84 of file DeclTemplate.h.
Iterates through the template parameters in this list.
Definition at line 81 of file DeclTemplate.h.
|
protected |
Definition at line 31 of file DeclTemplate.cpp.
References begin(), clang::Decl::isTemplateParameterPack(), and P.
Referenced by Create().
Definition at line 93 of file DeclTemplate.h.
Definition at line 96 of file DeclTemplate.h.
|
inline |
Definition at line 86 of file DeclTemplate.h.
Referenced by AdoptTemplateParameterList(), asArray(), clang::Sema::CheckTemplateArgumentList(), clang::Sema::CheckTemplateParameterList(), end(), GenerateInjectedTemplateArgs(), getMinRequiredArguments(), getParam(), clang::ASTNodeImporter::ImportTemplateParameterList(), TemplateParameterList(), and clang::Sema::TemplateParameterListsAreEqual().
|
inline |
Definition at line 87 of file DeclTemplate.h.
|
inline |
Determine whether this template parameter list contains an unexpanded parameter pack.
Definition at line 126 of file DeclTemplate.h.
|
static |
Definition at line 57 of file DeclTemplate.cpp.
References clang::ASTContext::Allocate(), and TemplateParameterList().
Referenced by clang::Sema::ActOnTemplateParameterList(), createMakeIntegerSeqParameterList(), getGenericLambdaTemplateParameterList(), clang::ASTNodeImporter::ImportTemplateParameterList(), clang::Sema::MatchTemplateParametersToScopeSpecifier(), clang::ASTReader::ReadTemplateParameterList(), and clang::TemplateDeclInstantiator::SubstTemplateParams().
|
inline |
Definition at line 88 of file DeclTemplate.h.
References begin().
Referenced by AdoptTemplateParameterList(), asArray(), clang::Sema::CheckTemplateArgumentList(), clang::Sema::CheckTemplateParameterList(), GenerateInjectedTemplateArgs(), getMinRequiredArguments(), clang::ASTNodeImporter::ImportTemplateParameterList(), and clang::Sema::TemplateParameterListsAreEqual().
|
inline |
Definition at line 89 of file DeclTemplate.h.
References begin().
| unsigned TemplateParameterList::getDepth | ( | ) | const |
Get the depth of this template parameter list in the set of template parameter lists.
The first template parameter list in a declaration will have depth 0, the second template parameter list will have depth 1, etc.
Definition at line 97 of file DeclTemplate.cpp.
References getParam(), and size().
Referenced by hasDeducibleTemplateParameters(), isAtLeastAsSpecializedAs(), isSameAsPrimaryTemplate(), and clang::Sema::MarkDeducedTemplateParameters().
|
inline |
Definition at line 131 of file DeclTemplate.h.
Referenced by clang::Sema::ActOnTemplateTemplateParameter(), clang::ASTWriter::AddTemplateParameterList(), and clang::ASTNodeImporter::ImportTemplateParameterList().
| unsigned TemplateParameterList::getMinRequiredArguments | ( | ) | const |
Returns the minimum number of arguments needed to form a template specialization.
This may be fewer than the number of template parameters, if some of the parameters have default arguments or if there is a parameter pack.
Definition at line 66 of file DeclTemplate.cpp.
References begin(), end(), and P.
Referenced by clang::Sema::isStdInitializerList(), and LookupStdInitializerList().
Definition at line 100 of file DeclTemplate.h.
References begin(), and size().
Referenced by clang::Sema::ActOnClassTemplateSpecialization(), clang::comments::Sema::actOnTParamCommandParamNameArg(), clang::Sema::CheckLiteralOperatorDeclaration(), CheckTemplatePartialSpecializationArgs(), clang::PredefinedExpr::ComputeName(), DeduceTemplateArgumentsByTypeMatch(), DiagnoseUnexpandedParameterPacks(), FinishTemplateArgumentDeduction(), clang::Sema::FinishTemplateArgumentDeduction(), getDepth(), clang::comments::TParamCommandComment::getParamName(), clang::Sema::getTemplateArgumentBindingsText(), isSameAsPrimaryTemplate(), isSameTemplateParameterList(), clang::Sema::isStdInitializerList(), IsStructurallyEquivalent(), LookupStdInitializerList(), clang::Sema::RebuildTemplateParamsInCurrentInstantiation(), and clang::Sema::SubstituteExplicitTemplateArguments().
Definition at line 105 of file DeclTemplate.h.
|
inline |
Definition at line 132 of file DeclTemplate.h.
Referenced by clang::Sema::ActOnClassTemplateSpecialization(), clang::Sema::ActOnCXXMemberDeclarator(), clang::Sema::ActOnTemplateTemplateParameter(), clang::Sema::ActOnVariableDeclarator(), clang::ASTWriter::AddTemplateParameterList(), DiagnoseTemplateParameterListArityMismatch(), and clang::ASTNodeImporter::ImportTemplateParameterList().
|
inline |
Definition at line 134 of file DeclTemplate.h.
Referenced by clang::Sema::CheckTemplateArgumentList(), clang::Sema::CheckTemplateDeclScope(), and diagnoseArityMismatch().
|
inline |
Definition at line 130 of file DeclTemplate.h.
Referenced by clang::Sema::ActOnClassTemplateSpecialization(), clang::Sema::ActOnCXXMemberDeclarator(), clang::Sema::ActOnTemplatedFriendTag(), clang::Sema::ActOnVariableDeclarator(), clang::ASTWriter::AddTemplateParameterList(), clang::Sema::CheckTemplateDeclScope(), DiagnoseTemplateParameterListArityMismatch(), clang::ASTNodeImporter::ImportTemplateParameterList(), and IsStructurallyEquivalent().
|
inlineprotected |
Definition at line 66 of file DeclTemplate.h.
|
inline |
Definition at line 91 of file DeclTemplate.h.
Referenced by clang::Sema::ActOnClassTemplateSpecialization(), clang::Sema::ActOnCXXMemberDeclarator(), clang::Sema::ActOnTemplatedFriendTag(), clang::Sema::ActOnTemplateTemplateParameter(), clang::comments::Sema::actOnTParamCommandParamNameArg(), clang::Sema::ActOnVariableDeclarator(), clang::ASTWriter::AddTemplateParameterList(), asArray(), clang::Sema::CheckClassTemplate(), clang::Sema::CheckLiteralOperatorDeclaration(), CheckTemplatePartialSpecializationArgs(), clang::PredefinedExpr::ComputeName(), clang::Sema::DeduceTemplateArguments(), diagnoseArityMismatch(), DiagnoseTemplateParameterListArityMismatch(), DiagnoseUnexpandedParameterPacks(), FinishTemplateArgumentDeduction(), clang::Sema::FinishTemplateArgumentDeduction(), getDepth(), clang::ClassTemplateDecl::getInjectedClassNameSpecialization(), clang::FunctionTemplateDecl::getInjectedTemplateArgs(), clang::Sema::getMoreSpecializedPartialSpecialization(), getParam(), clang::Sema::getTemplateArgumentBindingsText(), hasDeducibleTemplateParameters(), clang::ASTNodeImporter::ImportTemplateParameterList(), isAtLeastAsSpecializedAs(), isSameAsPrimaryTemplate(), isSameTemplateParameterList(), IsStructurallyEquivalent(), clang::Sema::LookupLiteralOperator(), clang::Sema::MarkDeducedTemplateParameters(), clang::Sema::RebuildTemplateParamsInCurrentInstantiation(), ResolveOverloadForDeduction(), clang::Sema::SubstituteExplicitTemplateArguments(), clang::TemplateDeclInstantiator::SubstTemplateParams(), and clang::Sema::TemplateParameterListsAreEqual().
|
friend |
Definition at line 139 of file DeclTemplate.h.
| friend clang::TemplateParameterList::TrailingObjects |
Definition at line 138 of file DeclTemplate.h.
1.8.6