clang API Documentation
#include <Template.h>


Definition at line 364 of file Template.h.
| typedef SmallVectorImpl<std::pair<ClassTemplateDecl *, ClassTemplatePartialSpecializationDecl *> >::iterator clang::TemplateDeclInstantiator::delayed_partial_spec_iterator |
Definition at line 464 of file Template.h.
| clang::TemplateDeclInstantiator::TemplateDeclInstantiator | ( | Sema & | SemaRef, |
| DeclContext * | Owner, | ||
| const MultiLevelTemplateArgumentList & | TemplateArgs | ||
| ) | [inline] |
Definition at line 382 of file Template.h.
| delayed_partial_spec_iterator clang::TemplateDeclInstantiator::delayed_partial_spec_begin | ( | ) | [inline] |
Return an iterator to the beginning of the set of "delayed" partial specializations, which must be passed to InstantiateClassTemplatePartialSpecialization once the class definition has been completed.
Definition at line 470 of file Template.h.
Referenced by clang::Sema::InstantiateClass().
| delayed_partial_spec_iterator clang::TemplateDeclInstantiator::delayed_partial_spec_end | ( | ) | [inline] |
Return an iterator to the end of the set of "delayed" partial specializations, which must be passed to InstantiateClassTemplatePartialSpecialization once the class definition has been completed.
Definition at line 478 of file Template.h.
Referenced by clang::Sema::InstantiateClass().
| void clang::TemplateDeclInstantiator::disableLateAttributeInstantiation | ( | ) | [inline] |
Definition at line 453 of file Template.h.
Referenced by clang::Sema::InstantiateClass().
| void clang::TemplateDeclInstantiator::enableLateAttributeInstantiation | ( | Sema::LateInstantiatedAttrVec * | LA | ) | [inline] |
Definition at line 447 of file Template.h.
References clang::Sema::CurrentInstantiationScope.
Referenced by clang::Sema::InstantiateClass().
| LocalInstantiationScope* clang::TemplateDeclInstantiator::getStartingScope | ( | ) | const [inline] |
Definition at line 458 of file Template.h.
Referenced by clang::Sema::InstantiateClass().
| bool TemplateDeclInstantiator::InitFunctionInstantiation | ( | FunctionDecl * | New, |
| FunctionDecl * | Tmpl | ||
| ) |
Initializes the common fields of an instantiation function declaration (New) from the corresponding fields of its template (Tmpl).
Definition at line 2723 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::ActiveTemplateInstantiations, clang::FunctionProtoType::arg_type_begin(), clang::Sema::Context, clang::EST_BasicNoexcept, clang::EST_DynamicNone, clang::EST_None, clang::EST_Unevaluated, clang::EST_Uninstantiated, clang::FunctionProtoType::ExtProtoInfo::ExceptionSpecDecl, clang::FunctionProtoType::ExtProtoInfo::ExceptionSpecTemplate, clang::FunctionProtoType::ExtProtoInfo::ExceptionSpecType, clang::FunctionProtoType::getExtProtoInfo(), clang::ASTContext::getFunctionType(), clang::Sema::getLangOpts(), clang::FunctionType::getNoReturnAttr(), clang::FunctionProtoType::getNumArgs(), clang::FunctionType::getResultType(), clang::ValueDecl::getType(), clang::FunctionProtoType::hasExceptionSpec(), clang::Sema::InstantiateAttrs(), InstantiateExceptionSpec(), clang::FunctionDecl::isDefined(), clang::FunctionDecl::isDeleted(), clang::FunctionDecl::setDeletedAsWritten(), and clang::ValueDecl::setType().
Referenced by InitMethodInstantiation(), and VisitFunctionDecl().
| bool TemplateDeclInstantiator::InitMethodInstantiation | ( | CXXMethodDecl * | New, |
| CXXMethodDecl * | Tmpl | ||
| ) |
Initializes common fields of an instantiated method declaration (New) from the corresponding fields of its template (Tmpl).
Definition at line 2802 of file SemaTemplateInstantiateDecl.cpp.
References clang::Decl::getAccess(), InitFunctionInstantiation(), clang::FunctionDecl::isVirtualAsWritten(), clang::Decl::setAccess(), and clang::FunctionDecl::setVirtualAsWritten().
Referenced by VisitCXXMethodDecl().
| ClassTemplatePartialSpecializationDecl * TemplateDeclInstantiator::InstantiateClassTemplatePartialSpecialization | ( | ClassTemplateDecl * | ClassTemplate, |
| ClassTemplatePartialSpecializationDecl * | PartialSpec | ||
| ) |
Instantiate the declaration of a class template partial specialization.
| ClassTemplate | the (instantiated) class template that is partially |
| PartialSpec | the (uninstantiated) class template partial specialization that we are instantiating. |
Definition at line 2329 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::CheckTemplateArgumentList(), clang::Sema::Context, clang::ClassTemplatePartialSpecializationDecl::Create(), clang::Sema::Diag(), clang::ClassTemplateDecl::findPartialSpecialization(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::ClassTemplatePartialSpecializationDecl::getNumTemplateArgsAsWritten(), clang::TagDecl::getTagKind(), clang::ClassTemplatePartialSpecializationDecl::getTemplateArgsAsWritten(), clang::ClassTemplatePartialSpecializationDecl::getTemplateParameters(), clang::ASTContext::getTemplateSpecializationType(), clang::ASTContext::getTemplateSpecializationTypeInfo(), clang::TypeSourceInfo::getType(), clang::ASTContext::getTypeDeclType(), clang::ClassTemplatePartialSpecializationDecl::setInstantiatedFromMember(), clang::ClassTemplateSpecializationDecl::setTypeAsWritten(), clang::Sema::Subst(), SubstQualifier(), and SubstTemplateParams().
Referenced by clang::Sema::InstantiateClass(), and VisitClassTemplatePartialSpecializationDecl().
Definition at line 743 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::ActOnEnumBody(), clang::DeclContext::addDecl(), clang::Sema::CheckEnumConstant(), clang::Sema::ConstantEvaluated, clang::Sema::CurrentInstantiationScope, clang::EnumDecl::enumerator_begin(), clang::EnumDecl::enumerator_end(), clang::ActionResult< PtrTy, CompressInvalid >::get(), clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::Decl::getLocation(), clang::TagDecl::getRBraceLoc(), clang::Sema::InstantiateAttrs(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::DeclContext::isFunctionOrMethod(), clang::ActionResult< PtrTy, CompressInvalid >::isInvalid(), isInvalid(), clang::EnumDecl::isScoped(), clang::Sema::Owned(), clang::Decl::setAccess(), clang::Decl::setInvalidDecl(), clang::Decl::setLocation(), clang::TagDecl::startDefinition(), and clang::Sema::SubstExpr().
Referenced by clang::Sema::InstantiateEnum(), and VisitEnumDecl().
| Decl * TemplateDeclInstantiator::InstantiateTypedefNameDecl | ( | TypedefNameDecl * | D, |
| bool | IsTypeAlias | ||
| ) |
Definition at line 185 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::Context, clang::TypedefDecl::Create(), clang::TypeAliasDecl::Create(), clang::Sema::FindInstantiatedDecl(), clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::NamedDecl::getDeclName(), clang::NamedDecl::getIdentifier(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::QualType::getNonReferenceType(), clang::Redeclarable< decl_type >::getPreviousDecl(), clang::Sema::getSourceManager(), clang::Sema::getStdNamespace(), clang::ASTContext::getTrivialTypeSourceInfo(), clang::TypeSourceInfo::getType(), clang::TagDecl::getTypedefNameForAnonDecl(), clang::TypedefNameDecl::getTypeSourceInfo(), clang::DecltypeType::getUnderlyingExpr(), clang::TypedefNameDecl::getUnderlyingType(), clang::TagDecl::hasNameForLinkage(), clang::Sema::InstantiateAttrs(), clang::ASTContext::IntTy, clang::Sema::isIncompatibleTypedef(), clang::SourceManager::isInSystemHeader(), clang::Type::isReferenceType(), clang::IdentifierInfo::isStr(), clang::Sema::MarkDeclarationsReferencedInType(), clang::Decl::setInvalidDecl(), clang::TagDecl::setTypedefNameForAnonDecl(), and clang::Sema::SubstType().
Referenced by VisitTypeAliasDecl(), VisitTypeAliasTemplateDecl(), and VisitTypedefDecl().
| TypeSourceInfo * TemplateDeclInstantiator::SubstFunctionType | ( | FunctionDecl * | D, |
| SmallVectorImpl< ParmVarDecl * > & | Params | ||
| ) |
Definition at line 2443 of file SemaTemplateInstantiateDecl.cpp.
References clang::TypeLoc::castAs(), clang::Sema::CurrentInstantiationScope, clang::FunctionTypeLoc::getArg(), clang::TypeLoc::getAs(), clang::NamedDecl::getDeclName(), clang::Sema::getNumArgumentsInExpansion(), clang::DeclContext::getParent(), clang::ValueDecl::getType(), clang::TypeSourceInfo::getTypeLoc(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::DeclaratorDecl::getTypeSpecStartLoc(), clang::TypeLoc::IgnoreParens(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::LocalInstantiationScope::InstantiatedLocalPackArg(), clang::ParmVarDecl::isParameterPack(), clang::LocalInstantiationScope::MakeInstantiatedLocalArgPack(), clang::Sema::SubstFunctionDeclType(), and VisitParmVarDecl().
Referenced by VisitCXXMethodDecl(), and VisitFunctionDecl().
| bool TemplateDeclInstantiator::SubstQualifier | ( | const DeclaratorDecl * | OldDecl, |
| DeclaratorDecl * | NewDecl | ||
| ) |
Definition at line 28 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclaratorDecl::getQualifierLoc(), clang::DeclaratorDecl::setQualifierInfo(), and clang::Sema::SubstNestedNameSpecifierLoc().
Referenced by InstantiateClassTemplatePartialSpecialization(), VisitCXXRecordDecl(), VisitEnumDecl(), and VisitVarDecl().
Definition at line 44 of file SemaTemplateInstantiateDecl.cpp.
References clang::TagDecl::getQualifierLoc(), clang::TagDecl::setQualifierInfo(), and clang::Sema::SubstNestedNameSpecifierLoc().
| TemplateParameterList * TemplateDeclInstantiator::SubstTemplateParams | ( | TemplateParameterList * | L | ) |
Instantiates a nested template parameter list in the current instantiation context.
| L | The parameter list to instantiate |
Definition at line 2291 of file SemaTemplateInstantiateDecl.cpp.
References clang::TemplateParameterList::begin(), clang::Sema::Context, clang::TemplateParameterList::Create(), clang::TemplateParameterList::end(), clang::TemplateParameterList::getLAngleLoc(), clang::TemplateParameterList::getRAngleLoc(), clang::TemplateParameterList::getTemplateLoc(), clang::Decl::isInvalidDecl(), NULL, clang::TemplateParameterList::size(), and clang::declvisitor::Base< declvisitor::make_ptr, TemplateDeclInstantiator, Decl * >::Visit().
Referenced by InstantiateClassTemplatePartialSpecialization(), VisitClassTemplateDecl(), VisitCXXMethodDecl(), VisitFunctionTemplateDecl(), VisitTemplateTemplateParmDecl(), and VisitTypeAliasTemplateDecl().
| Decl * TemplateDeclInstantiator::VisitAccessSpecDecl | ( | AccessSpecDecl * | D | ) |
| Decl * TemplateDeclInstantiator::VisitClassScopeFunctionSpecializationDecl | ( | ClassScopeFunctionSpecializationDecl * | D | ) |
Definition at line 2227 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::CheckFunctionTemplateSpecialization(), clang::Sema::Context, clang::Sema::CurContext, clang::Sema::ForRedeclaration, clang::FunctionDecl::getNameInfo(), clang::ClassScopeFunctionSpecializationDecl::getSpecialization(), clang::ClassScopeFunctionSpecializationDecl::hasExplicitTemplateArgs(), clang::Sema::LookupOrdinaryName, clang::Sema::LookupQualifiedName(), clang::ASTContext::setClassScopeSpecializationPattern(), clang::Decl::setInvalidDecl(), clang::ClassScopeFunctionSpecializationDecl::templateArgs(), and VisitCXXMethodDecl().
| Decl * TemplateDeclInstantiator::VisitClassTemplateDecl | ( | ClassTemplateDecl * | D | ) |
Definition at line 812 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::CXXScopeSpec::Adopt(), clang::Sema::CheckTemplateParameterList(), clang::Sema::computeDeclContext(), clang::Sema::Context, clang::CXXRecordDecl::Create(), clang::ClassTemplateDecl::Create(), clang::Sema::Diag(), clang::Sema::FindInstantiatedContext(), clang::Decl::FOK_None, clang::Sema::ForRedeclaration, clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::NamedDecl::getDeclName(), clang::Decl::getFriendObjectKind(), clang::NamedDecl::getIdentifier(), clang::ClassTemplateDecl::getInjectedClassNameSpecialization(), clang::ASTContext::getInjectedClassNameType(), clang::Decl::getLexicalDeclContext(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::DeclContext::getParent(), clang::ClassTemplateDecl::getPartialSpecializations(), clang::CXXRecordDecl::getPreviousDecl(), clang::TagDecl::getQualifierLoc(), clang::NestedNameSpecifierLoc::getSourceRange(), clang::TagDecl::getTagKind(), clang::ClassTemplateDecl::getTemplatedDecl(), clang::TemplateDecl::getTemplateParameters(), clang::DeclContext::isNamespace(), clang::Decl::isOutOfLine(), clang::IdentifierInfo::isStr(), clang::DeclContext::isTranslationUnit(), clang::DeclContext::lookup(), clang::Sema::LookupOrdinaryName, clang::Sema::LookupQualifiedName(), clang::DeclContext::makeDeclVisibleInContext(), NULL, clang::Decl::setAccess(), clang::RedeclarableTemplateDecl::setInstantiatedFromMemberTemplate(), clang::Decl::setLexicalDeclContext(), clang::Decl::setObjectOfFriendDecl(), clang::TagDecl::setQualifierInfo(), clang::Sema::SubstNestedNameSpecifierLoc(), SubstTemplateParams(), clang::Sema::TemplateParameterListsAreEqual(), clang::Sema::TPC_ClassTemplate, and clang::Sema::TPL_TemplateMatch.
| Decl * TemplateDeclInstantiator::VisitClassTemplatePartialSpecializationDecl | ( | ClassTemplatePartialSpecializationDecl * | D | ) |
Definition at line 999 of file SemaTemplateInstantiateDecl.cpp.
References clang::ClassTemplateDecl::findPartialSpecInstantiatedFromMember(), clang::NamedDecl::getDeclName(), clang::ClassTemplateSpecializationDecl::getSpecializedTemplate(), InstantiateClassTemplatePartialSpecialization(), and clang::DeclContext::lookup().
| Decl * TemplateDeclInstantiator::VisitCXXConstructorDecl | ( | CXXConstructorDecl * | D | ) |
Definition at line 1741 of file SemaTemplateInstantiateDecl.cpp.
References VisitCXXMethodDecl().
| Decl * TemplateDeclInstantiator::VisitCXXConversionDecl | ( | CXXConversionDecl * | D | ) |
Definition at line 1749 of file SemaTemplateInstantiateDecl.cpp.
References VisitCXXMethodDecl().
| Decl * TemplateDeclInstantiator::VisitCXXDestructorDecl | ( | CXXDestructorDecl * | D | ) |
Definition at line 1745 of file SemaTemplateInstantiateDecl.cpp.
References VisitCXXMethodDecl().
| Decl * TemplateDeclInstantiator::VisitCXXMethodDecl | ( | CXXMethodDecl * | D, |
| TemplateParameterList * | TemplateParams = 0, |
||
| bool | IsClassScopeSpecialization = false |
||
| ) |
Definition at line 1453 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::MultiLevelTemplateArgumentList::addOuterTemplateArguments(), adjustFunctionTypeForInstantiation(), clang::CXXScopeSpec::Adopt(), clang::Sema::CheckFriendAccess(), clang::Sema::CheckFunctionDeclaration(), clang::Sema::CheckOverrideControl(), clang::Sema::CheckPureMethod(), clang::LookupResult::clear(), clang::Sema::computeDeclContext(), clang::Sema::Context, clang::FunctionTemplateDecl::Create(), clang::CXXMethodDecl::Create(), clang::CXXConstructorDecl::Create(), clang::CXXDestructorDecl::Create(), clang::CXXConversionDecl::Create(), clang::TemplateArgumentList::CreateCopy(), clang::LookupResult::empty(), clang::Sema::FindInstantiatedContext(), clang::FunctionTemplateDecl::findSpecialization(), clang::Decl::FOK_None, clang::Sema::ForRedeclaration, clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::FunctionDecl::getDescribedFunctionTemplate(), clang::Decl::getFriendObjectKind(), clang::DeclaratorDecl::getInnerLocStart(), clang::MultiLevelTemplateArgumentList::getInnermost(), clang::Decl::getLexicalDeclContext(), clang::Decl::getLocation(), clang::Decl::getLocEnd(), clang::FunctionDecl::getNameInfo(), clang::FunctionDecl::getNumParams(), clang::DeclaratorDecl::getNumTemplateParameterLists(), clang::Redeclarable< decl_type >::getPreviousDecl(), clang::DeclaratorDecl::getQualifierLoc(), clang::DeclaratorDecl::getTemplateParameterList(), clang::QualType::IgnoreParens(), InitMethodInstantiation(), clang::FunctionDecl::isConstexpr(), clang::FunctionDecl::isDeletedAsWritten(), clang::FunctionDecl::isExplicitlyDefaulted(), clang::FunctionDecl::isInlined(), clang::FunctionDecl::isInlineSpecified(), clang::FunctionDecl::isOutOfLine(), clang::FunctionDecl::isPure(), clang::LookupResult::isSingleTagDecl(), clang::CXXMethodDecl::isStatic(), clang::Sema::LookupOrdinaryName, clang::Sema::LookupQualifiedName(), clang::DeclContext::makeDeclVisibleInContext(), NULL, P, clang::FunctionDecl::param_begin(), clang::Sema::RequireCompleteDeclContext(), clang::SC_None, clang::SC_Static, clang::Decl::setAccess(), clang::Sema::SetDeclDefaulted(), clang::Sema::SetDeclDeleted(), clang::FunctionDecl::setImplicitlyInline(), clang::Decl::setLexicalDeclContext(), clang::Decl::setObjectOfFriendDecl(), clang::Sema::SubstDecl(), clang::Sema::SubstDeclarationNameInfo(), SubstFunctionType(), clang::Sema::SubstNestedNameSpecifierLoc(), clang::Sema::SubstParmTypes(), SubstTemplateParams(), and clang::TSK_ImplicitInstantiation.
Referenced by VisitClassScopeFunctionSpecializationDecl(), VisitCXXConstructorDecl(), VisitCXXConversionDecl(), VisitCXXDestructorDecl(), and VisitFunctionTemplateDecl().
| Decl * TemplateDeclInstantiator::VisitCXXRecordDecl | ( | CXXRecordDecl * | D | ) |
Definition at line 1074 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::AS_none, clang::Sema::Context, clang::CXXRecordDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::Sema::FindInstantiatedDecl(), clang::Decl::FOK_Declared, clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::Decl::getFriendObjectKind(), clang::NamedDecl::getIdentifier(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::CXXRecordDecl::getPreviousDecl(), clang::DeclContext::getRedeclContext(), clang::TagDecl::getTagKind(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::RecordDecl::isAnonymousStructOrUnion(), clang::DeclContext::isFunctionOrMethod(), clang::Decl::isImplicit(), clang::RecordDecl::isInjectedClassName(), clang::Decl::setAccess(), clang::RecordDecl::setAnonymousStructOrUnion(), clang::Decl::setImplicit(), clang::CXXRecordDecl::setInstantiationOfMemberClass(), clang::Decl::setObjectOfFriendDecl(), SubstQualifier(), and clang::TSK_ImplicitInstantiation.
Referenced by VisitVarDecl().
Definition at line 435 of file Template.h.
References clang::Sema::Diag(), clang::DiagnosticsEngine::Error, clang::DiagnosticsEngine::getCustomDiagID(), clang::Decl::getDeclKindName(), clang::Sema::getDiagnostics(), and clang::Decl::getLocation().
| Decl * TemplateDeclInstantiator::VisitEnumConstantDecl | ( | EnumConstantDecl * | D | ) |
Definition at line 808 of file SemaTemplateInstantiateDecl.cpp.
Definition at line 671 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::CheckEnumRedeclaration(), clang::Sema::CheckEnumUnderlyingType(), clang::Sema::Context, clang::EnumDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::Sema::FindInstantiatedDecl(), clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::EnumDecl::getDefinition(), clang::NamedDecl::getIdentifier(), clang::EnumDecl::getIntegerType(), clang::EnumDecl::getIntegerTypeSourceInfo(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::EnumDecl::getPreviousDecl(), clang::Sema::InstantiateAttrs(), clang::LocalInstantiationScope::InstantiatedLocal(), InstantiateEnumDefinition(), clang::ASTContext::IntTy, clang::TagDecl::isCompleteDefinition(), clang::EnumDecl::isFixed(), clang::DeclContext::isFunctionOrMethod(), clang::EnumDecl::isScoped(), clang::EnumDecl::isScopedUsingClassTag(), clang::Decl::setAccess(), clang::EnumDecl::setIntegerType(), clang::EnumDecl::setIntegerTypeSourceInfo(), SubstQualifier(), clang::Sema::SubstType(), and clang::TSK_ImplicitInstantiation.
Definition at line 446 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::CheckAlignasUnderalignment(), clang::Sema::CheckFieldDecl(), clang::Sema::ConstantEvaluated, clang::Sema::Context, clang::Sema::CurrentInstantiationScope, clang::Sema::Diag(), clang::Decl::getAccess(), clang::FieldDecl::getBitWidth(), clang::Decl::getDeclContext(), clang::NamedDecl::getDeclName(), clang::FieldDecl::getInClassInitStyle(), clang::DeclaratorDecl::getInnerLocStart(), clang::Decl::getLocation(), clang::TypeSourceInfo::getType(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::Decl::hasAttrs(), clang::Sema::InstantiateAttrs(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::Decl::isImplicit(), clang::ActionResult< PtrTy, CompressInvalid >::isInvalid(), clang::FieldDecl::isMutable(), clang::Sema::MarkDeclarationsReferencedInType(), clang::Decl::setAccess(), clang::Decl::setImplicit(), clang::ASTContext::setInstantiatedFromUnnamedFieldDecl(), clang::Decl::setInvalidDecl(), clang::Sema::SubstExpr(), clang::Sema::SubstType(), and clang::ActionResult< PtrTy, CompressInvalid >::takeAs().
| Decl * TemplateDeclInstantiator::VisitFriendDecl | ( | FriendDecl * | D | ) |
Definition at line 604 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::AS_public, clang::Sema::CheckFriendTypeDecl(), clang::Sema::Context, clang::FriendDecl::Create(), clang::FriendDecl::getFriendDecl(), clang::FriendDecl::getFriendLoc(), clang::FriendDecl::getFriendType(), clang::Decl::getLocation(), clang::Decl::getLocStart(), clang::FriendDecl::isUnsupportedFriend(), clang::Decl::setAccess(), clang::FriendDecl::setUnsupportedFriend(), clang::Sema::SubstType(), and clang::declvisitor::Base< declvisitor::make_ptr, TemplateDeclInstantiator, Decl * >::Visit().
| Decl * TemplateDeclInstantiator::VisitFunctionDecl | ( | FunctionDecl * | D, |
| TemplateParameterList * | TemplateParams = 0 |
||
| ) |
Normal class members are of more specific types and therefore don't make it here. This function serves two purposes: 1) instantiating function templates 2) substituting friend declarations FIXME: preserve function definitions in case #2
Definition at line 1149 of file SemaTemplateInstantiateDecl.cpp.
References adjustFunctionTypeForInstantiation(), clang::CXXScopeSpec::Adopt(), clang::FunctionProtoType::arg_type_begin(), clang::FunctionProtoType::arg_type_end(), clang::Sema::BuildParmVarDeclForTypedef(), clang::Sema::CheckFunctionDeclaration(), clang::Sema::CheckFunctionTemplateSpecialization(), clang::Sema::computeDeclContext(), clang::Sema::Context, clang::FunctionTemplateDecl::Create(), clang::FunctionDecl::Create(), clang::TemplateArgumentList::CreateCopy(), clang::Sema::Diag(), clang::Sema::Diags, clang::Sema::FindInstantiatedContext(), clang::Sema::FindInstantiatedDecl(), clang::FunctionTemplateDecl::findSpecialization(), clang::Decl::FOK_None, clang::Sema::ForRedeclaration, clang::FunctionDecl::getCanonicalDecl(), clang::Decl::getDeclContext(), clang::NamedDecl::getDeclName(), clang::FunctionDecl::getDependentSpecializationInfo(), clang::FunctionDecl::getDescribedFunctionTemplate(), clang::DiagnosticsEngine::getDiagnosticLevel(), clang::Decl::getFriendObjectKind(), clang::DeclaratorDecl::getInnerLocStart(), clang::MultiLevelTemplateArgumentList::getInnermost(), clang::Sema::getLangOpts(), clang::Decl::getLocation(), clang::FunctionDecl::getMemberSpecializationInfo(), clang::FunctionDecl::getNameInfo(), clang::Redeclarable< decl_type >::getPreviousDecl(), clang::FunctionTemplateDecl::getPreviousDecl(), clang::DeclaratorDecl::getQualifierLoc(), clang::FunctionDecl::getStorageClass(), clang::FunctionDecl::getTemplateInstantiationPattern(), clang::FunctionDecl::getTemplateSpecializationKind(), clang::ValueDecl::getType(), clang::FunctionDecl::hasWrittenPrototype(), clang::Decl::IDNS_Ordinary, clang::DiagnosticsEngine::Ignored, clang::QualType::IgnoreParens(), InitFunctionInstantiation(), clang::FunctionDecl::isConstexpr(), clang::FunctionDecl::isDefaulted(), clang::FunctionDecl::isDefined(), clang::DeclContext::isFileContext(), clang::DeclContext::isFunctionOrMethod(), clang::Decl::isInIdentifierNamespace(), clang::FunctionDecl::isInlined(), clang::FunctionDecl::isInlineSpecified(), clang::FunctionDecl::isOutOfLine(), clang::FunctionDecl::isOverloadedOperator(), clang::DeclContext::isRecord(), clang::FunctionDecl::isThisDeclarationADefinition(), clang::Sema::LookupOrdinaryName, clang::Sema::LookupQualifiedName(), clang::DeclContext::makeDeclVisibleInContext(), P, Param, clang::Sema::PendingLocalImplicitInstantiations, clang::Redeclarable< decl_type >::redecls_begin(), clang::Redeclarable< decl_type >::redecls_end(), clang::FunctionDecl::setDescribedFunctionTemplate(), clang::FunctionDecl::setImplicitlyInline(), clang::RedeclarableTemplateDecl::setInstantiatedFromMemberTemplate(), clang::Decl::setInvalidDecl(), clang::Decl::setLexicalDeclContext(), clang::Decl::setNonMemberOperator(), clang::Decl::setObjectOfFriendDecl(), clang::DeclaratorDecl::setQualifierInfo(), clang::ParmVarDecl::setScopeInfo(), clang::Sema::Subst(), SubstFunctionType(), clang::Sema::SubstNestedNameSpecifierLoc(), clang::TSK_ImplicitInstantiation, and clang::TSK_Undeclared.
Referenced by VisitFunctionTemplateDecl().
| Decl * TemplateDeclInstantiator::VisitFunctionTemplateDecl | ( | FunctionTemplateDecl * | D | ) |
Definition at line 1023 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::CheckFriendAccess(), clang::Decl::FOK_None, clang::Decl::getAccess(), clang::Decl::getDeclContext(), clang::Decl::getFriendObjectKind(), clang::FunctionTemplateDecl::getInstantiatedFromMemberTemplate(), clang::FunctionTemplateDecl::getPreviousDecl(), clang::FunctionTemplateDecl::getTemplatedDecl(), clang::TemplateDecl::getTemplateParameters(), clang::DeclContext::isRecord(), clang::FunctionDecl::isThisDeclarationADefinition(), NULL, clang::Decl::setAccess(), clang::RedeclarableTemplateDecl::setInstantiatedFromMemberTemplate(), SubstTemplateParams(), VisitCXXMethodDecl(), and VisitFunctionDecl().
| Decl * TemplateDeclInstantiator::VisitIndirectFieldDecl | ( | IndirectFieldDecl * | D | ) |
Definition at line 575 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::IndirectFieldDecl::chain_begin(), clang::IndirectFieldDecl::chain_end(), clang::Sema::Context, clang::IndirectFieldDecl::Create(), clang::Sema::FindInstantiatedDecl(), clang::Decl::getAccess(), clang::IndirectFieldDecl::getChainingSize(), clang::NamedDecl::getIdentifier(), clang::Decl::getLocation(), clang::Decl::isImplicit(), clang::Decl::setAccess(), and clang::Decl::setImplicit().
Definition at line 159 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::Context, clang::LabelDecl::Create(), clang::NamedDecl::getIdentifier(), and clang::Decl::getLocation().
| Decl * TemplateDeclInstantiator::VisitMSPropertyDecl | ( | MSPropertyDecl * | D | ) |
Definition at line 528 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::Context, clang::Sema::Diag(), clang::Decl::getAccess(), clang::NamedDecl::getDeclName(), clang::MSPropertyDecl::getGetterId(), clang::Decl::getLocation(), clang::DeclaratorDecl::getLocStart(), clang::NamedDecl::getName(), clang::MSPropertyDecl::getSetterId(), clang::TypeSourceInfo::getType(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::Sema::InstantiateAttrs(), clang::Sema::MarkDeclarationsReferencedInType(), clang::Decl::setAccess(), clang::Decl::setInvalidDecl(), and clang::Sema::SubstType().
| Decl * TemplateDeclInstantiator::VisitNamespaceAliasDecl | ( | NamespaceAliasDecl * | D | ) |
Definition at line 172 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::Context, clang::NamespaceAliasDecl::Create(), clang::NamespaceAliasDecl::getAliasLoc(), clang::NamedDecl::getIdentifier(), clang::NamespaceAliasDecl::getNamespace(), clang::NamespaceAliasDecl::getNamespaceLoc(), clang::NamespaceAliasDecl::getQualifierLoc(), and clang::NamespaceAliasDecl::getTargetNameLoc().
| Decl * TemplateDeclInstantiator::VisitNamespaceDecl | ( | NamespaceDecl * | D | ) |
Definition at line 167 of file SemaTemplateInstantiateDecl.cpp.
| Decl * TemplateDeclInstantiator::VisitNonTypeTemplateParmDecl | ( | NonTypeTemplateParmDecl * | D | ) |
Definition at line 1782 of file SemaTemplateInstantiateDecl.cpp.
References clang::AS_public, clang::TypeLoc::castAs(), clang::Sema::CheckNonTypeTemplateParameterType(), clang::Sema::CheckPackExpansion(), clang::Sema::CheckParameterPacksForExpansion(), clang::Sema::collectUnexpandedParameterPacks(), clang::Sema::Context, clang::NonTypeTemplateParmDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::NamedDecl::getDeclName(), clang::NonTypeTemplateParmDecl::getDefaultArgument(), clang::TemplateParmPosition::getDepth(), clang::PackExpansionTypeLoc::getEllipsisLoc(), clang::NonTypeTemplateParmDecl::getExpansionTypeSourceInfo(), clang::NamedDecl::getIdentifier(), clang::DeclaratorDecl::getInnerLocStart(), clang::Decl::getLocation(), clang::PackExpansionType::getNumExpansions(), clang::NonTypeTemplateParmDecl::getNumExpansionTypes(), clang::MultiLevelTemplateArgumentList::getNumLevels(), clang::PackExpansionTypeLoc::getPatternLoc(), clang::TemplateParmPosition::getPosition(), clang::TypeSourceInfo::getType(), clang::TypeSourceInfo::getTypeLoc(), clang::ConcreteTypeLoc< Base, Derived, TypeClass, LocalData >::getTypePtr(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::ASTContext::IntTy, clang::NonTypeTemplateParmDecl::isExpandedParameterPack(), clang::QualType::isNull(), clang::NonTypeTemplateParmDecl::isPackExpansion(), clang::NonTypeTemplateParmDecl::isParameterPack(), Param, clang::Decl::setAccess(), and clang::Sema::SubstType().
| Decl * TemplateDeclInstantiator::VisitOMPThreadPrivateDecl | ( | OMPThreadPrivateDecl * | D | ) |
Definition at line 2258 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::CheckOMPThreadPrivateDecl(), clang::Decl::getLocation(), clang::Sema::SubstExpr(), clang::ActionResult< PtrTy, CompressInvalid >::take(), clang::OMPThreadPrivateDecl::varlist_begin(), and clang::OMPThreadPrivateDecl::varlist_end().
| ParmVarDecl * TemplateDeclInstantiator::VisitParmVarDecl | ( | ParmVarDecl * | D | ) |
Definition at line 1753 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::SubstParmVarDecl().
Referenced by SubstFunctionType().
| Decl * TemplateDeclInstantiator::VisitStaticAssertDecl | ( | StaticAssertDecl * | D | ) |
Definition at line 652 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::BuildStaticAssertDeclaration(), clang::Sema::ConstantEvaluated, clang::ActionResult< PtrTy, CompressInvalid >::get(), clang::StaticAssertDecl::getAssertExpr(), clang::Decl::getLocation(), clang::StaticAssertDecl::getMessage(), clang::StaticAssertDecl::getRParenLoc(), clang::StaticAssertDecl::isFailed(), clang::ActionResult< PtrTy, CompressInvalid >::isInvalid(), and clang::Sema::SubstExpr().
| Decl * TemplateDeclInstantiator::VisitTemplateTemplateParmDecl | ( | TemplateTemplateParmDecl * | D | ) |
Definition at line 1949 of file SemaTemplateInstantiateDecl.cpp.
References clang::AS_public, clang::Sema::CheckParameterPacksForExpansion(), collectUnexpandedParameterPacks(), clang::Sema::Context, clang::TemplateTemplateParmDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::TemplateTemplateParmDecl::getDefaultArgument(), clang::TemplateParmPosition::getDepth(), clang::TemplateTemplateParmDecl::getExpansionTemplateParameters(), clang::NamedDecl::getIdentifier(), clang::Decl::getLocation(), clang::TemplateTemplateParmDecl::getNumExpansionTemplateParameters(), clang::MultiLevelTemplateArgumentList::getNumLevels(), clang::TemplateParmPosition::getPosition(), clang::TemplateParameterList::getSourceRange(), clang::TemplateDecl::getTemplateParameters(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::TemplateTemplateParmDecl::isExpandedParameterPack(), clang::TemplateTemplateParmDecl::isPackExpansion(), clang::TemplateTemplateParmDecl::isParameterPack(), Param, clang::TemplateTemplateParmDecl::setDefaultArgument(), and SubstTemplateParams().
| Decl * TemplateDeclInstantiator::VisitTemplateTypeParmDecl | ( | TemplateTypeParmDecl * | D | ) |
Definition at line 1758 of file SemaTemplateInstantiateDecl.cpp.
References clang::AS_public, clang::Sema::Context, clang::TemplateTypeParmDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::TemplateTypeParmDecl::getDefaultArgumentInfo(), clang::TemplateTypeParmDecl::getDepth(), clang::NamedDecl::getIdentifier(), clang::TemplateTypeParmDecl::getIndex(), clang::Decl::getLocation(), clang::TypeDecl::getLocStart(), clang::MultiLevelTemplateArgumentList::getNumLevels(), clang::TypeDecl::getTypeForDecl(), clang::TemplateTypeParmDecl::hasDefaultArgument(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::TemplateTypeParmDecl::isParameterPack(), clang::Type::isTemplateTypeParmType(), clang::Decl::setAccess(), and clang::TemplateTypeParmDecl::wasDeclaredWithTypename().
| Decl * TemplateDeclInstantiator::VisitTranslationUnitDecl | ( | TranslationUnitDecl * | D | ) |
Definition at line 154 of file SemaTemplateInstantiateDecl.cpp.
| Decl * TemplateDeclInstantiator::VisitTypeAliasDecl | ( | TypeAliasDecl * | D | ) |
Definition at line 266 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), and InstantiateTypedefNameDecl().
| Decl * TemplateDeclInstantiator::VisitTypeAliasTemplateDecl | ( | TypeAliasTemplateDecl * | D | ) |
Definition at line 273 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::Context, clang::TypeAliasTemplateDecl::Create(), clang::Decl::getAccess(), clang::NamedDecl::getDeclName(), clang::Decl::getLocation(), clang::Redeclarable< decl_type >::getPreviousDecl(), clang::TypeAliasTemplateDecl::getTemplatedDecl(), clang::TemplateDecl::getTemplateParameters(), InstantiateTypedefNameDecl(), clang::DeclContext::lookup(), clang::Decl::setAccess(), clang::RedeclarableTemplateDecl::setInstantiatedFromMemberTemplate(), clang::Redeclarable< decl_type >::setPreviousDeclaration(), and SubstTemplateParams().
| Decl * TemplateDeclInstantiator::VisitTypedefDecl | ( | TypedefDecl * | D | ) |
Definition at line 260 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), and InstantiateTypedefNameDecl().
| Decl * TemplateDeclInstantiator::VisitUnresolvedUsingTypenameDecl | ( | UnresolvedUsingTypenameDecl * | D | ) |
Definition at line 2178 of file SemaTemplateInstantiateDecl.cpp.
References clang::CXXScopeSpec::Adopt(), clang::Sema::BuildUsingDeclaration(), clang::Sema::Context, clang::Decl::getAccess(), clang::NamedDecl::getDeclName(), clang::Decl::getLocation(), clang::UnresolvedUsingTypenameDecl::getQualifierLoc(), clang::UnresolvedUsingTypenameDecl::getTypenameLoc(), clang::UnresolvedUsingTypenameDecl::getUsingLoc(), SemaRef, clang::ASTContext::setInstantiatedFromUsingDecl(), and clang::Sema::SubstNestedNameSpecifierLoc().
| Decl * TemplateDeclInstantiator::VisitUnresolvedUsingValueDecl | ( | UnresolvedUsingValueDecl * | D | ) |
Definition at line 2203 of file SemaTemplateInstantiateDecl.cpp.
References clang::CXXScopeSpec::Adopt(), clang::Sema::BuildUsingDeclaration(), clang::Sema::Context, clang::Decl::getAccess(), clang::UnresolvedUsingValueDecl::getNameInfo(), clang::UnresolvedUsingValueDecl::getQualifierLoc(), clang::UnresolvedUsingValueDecl::getUsingLoc(), SemaRef, clang::ASTContext::setInstantiatedFromUsingDecl(), clang::Sema::SubstDeclarationNameInfo(), and clang::Sema::SubstNestedNameSpecifierLoc().
Definition at line 2076 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::CXXScopeSpec::Adopt(), clang::Sema::BuildUsingShadowDecl(), clang::Sema::CheckInheritingConstructorUsingDecl(), clang::Sema::CheckUsingDeclQualifier(), clang::Sema::CheckUsingDeclRedeclaration(), clang::Sema::CheckUsingShadowDecl(), clang::Sema::Context, clang::UsingDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::DeclarationName::CXXConstructorName, clang::Sema::FindInstantiatedDecl(), clang::Sema::ForRedeclaration, clang::Decl::getAccess(), clang::Decl::getLocation(), clang::UsingDecl::getNameInfo(), clang::UsingDecl::getQualifierLoc(), clang::UsingShadowDecl::getTargetDecl(), clang::UsingDecl::getUsingLocation(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::DeclContext::isFunctionOrMethod(), clang::Decl::isInvalidDecl(), clang::DeclContext::isRecord(), clang::UsingDecl::isTypeName(), clang::Sema::LookupQualifiedName(), clang::Sema::LookupUsingDeclName, clang::Decl::setAccess(), clang::LookupResult::setHideTags(), clang::ASTContext::setInstantiatedFromUsingDecl(), clang::ASTContext::setInstantiatedFromUsingShadowDecl(), clang::Decl::setInvalidDecl(), clang::UsingDecl::shadow_begin(), clang::UsingDecl::shadow_end(), and clang::Sema::SubstNestedNameSpecifierLoc().
| Decl * TemplateDeclInstantiator::VisitUsingDirectiveDecl | ( | UsingDirectiveDecl * | D | ) |
Definition at line 2056 of file SemaTemplateInstantiateDecl.cpp.
References clang::DeclContext::addDecl(), clang::Sema::Context, clang::UsingDirectiveDecl::Create(), clang::UsingDirectiveDecl::getCommonAncestor(), clang::UsingDirectiveDecl::getIdentLocation(), clang::Decl::getLocation(), clang::UsingDirectiveDecl::getNamespaceKeyLocation(), clang::UsingDirectiveDecl::getNominatedNamespace(), clang::UsingDirectiveDecl::getQualifierLoc(), and clang::DeclContext::isFunctionOrMethod().
| Decl * TemplateDeclInstantiator::VisitUsingShadowDecl | ( | UsingShadowDecl * | D | ) |
Definition at line 2172 of file SemaTemplateInstantiateDecl.cpp.
Definition at line 314 of file SemaTemplateInstantiateDecl.cpp.
References clang::Sema::ActOnUninitializedDecl(), clang::DeclContext::addDecl(), clang::Sema::AddInitializerToDecl(), clang::VarDecl::CallInit, clang::Sema::CheckAlignasUnderalignment(), clang::Sema::CheckVariableDeclaration(), clang::Sema::ConstantEvaluated, clang::Sema::Context, clang::VarDecl::Create(), clang::Sema::CurrentInstantiationScope, clang::Sema::Diag(), clang::Sema::DiagnoseUnusedDecl(), clang::Sema::ForRedeclaration, clang::ActionResult< PtrTy, CompressInvalid >::get(), clang::Decl::getAccess(), clang::VarDecl::getAnyInitializer(), clang::NamedDecl::getDeclName(), clang::NamedDecl::getIdentifier(), clang::VarDecl::getInit(), clang::VarDecl::getInitStyle(), clang::DeclaratorDecl::getInnerLocStart(), clang::Sema::getLangOpts(), clang::Decl::getLexicalDeclContext(), clang::Decl::getLocation(), clang::VarDecl::getStorageClass(), clang::VarDecl::getTSCSpec(), clang::TypeSourceInfo::getType(), clang::ValueDecl::getType(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::DeclaratorDecl::getTypeSpecStartLoc(), clang::Decl::hasAttrs(), clang::Sema::inferObjCARCLifetime(), clang::Sema::InstantiateAttrs(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::VarDecl::isConstexpr(), clang::VarDecl::isCXXForRangeDecl(), clang::VarDecl::isDirectInit(), clang::DeclContext::isFunctionOrMethod(), clang::ActionResult< PtrTy, CompressInvalid >::isInvalid(), clang::Decl::isInvalidDecl(), clang::VarDecl::isOutOfLine(), clang::Decl::isReferenced(), clang::VarDecl::isStaticDataMember(), clang::Decl::isUsed(), clang::Sema::LookupOrdinaryName, clang::Sema::LookupQualifiedName(), clang::DeclContext::makeDeclVisibleInContext(), clang::Sema::PopExpressionEvaluationContext(), clang::Sema::PotentiallyEvaluated, clang::Sema::PushExpressionEvaluationContext(), clang::Decl::setAccess(), clang::VarDecl::setConstexpr(), clang::VarDecl::setCXXForRangeDecl(), clang::VarDecl::setInitStyle(), clang::ASTContext::setInstantiatedFromStaticDataMember(), clang::Decl::setInvalidDecl(), clang::Decl::setLexicalDeclContext(), clang::Decl::setReferenced(), clang::VarDecl::setTSCSpec(), clang::Decl::setUsed(), clang::Sema::SubstInitializer(), SubstQualifier(), clang::Sema::SubstType(), clang::ActionResult< PtrTy, CompressInvalid >::take(), clang::TSK_ImplicitInstantiation, and VisitCXXRecordDecl().