clang API Documentation
#include "clang/Sema/SemaInternal.h"
#include "TreeTransform.h"
#include "clang/AST/ASTConsumer.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/ASTLambda.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/Expr.h"
#include "clang/Basic/LangOptions.h"
#include "clang/Sema/DeclSpec.h"
#include "clang/Sema/Initialization.h"
#include "clang/Sema/Lookup.h"
#include "clang/Sema/Template.h"
#include "clang/Sema/TemplateDeduction.h"
Go to the source code of this file.
Namespaces | |
namespace | clang |
namespace | clang::sema |
Functions | |
static std::pair< unsigned, unsigned > | getDepthAndIndex (NamedDecl *ND) |
Retrieve the depth and index of a parameter pack. | |
static TemplateArgument | getPackSubstitutedTemplateArgument (Sema &S, TemplateArgument Arg) |
static bool | NeedsInstantiationAsFunctionType (TypeSourceInfo *T) |
Attr * | clang::sema::instantiateTemplateAttribute (const Attr *At, ASTContext &C, Sema &S, const MultiLevelTemplateArgumentList &TemplateArgs) |
static bool | DiagnoseUninstantiableTemplate (Sema &S, SourceLocation PointOfInstantiation, TagDecl *Instantiation, bool InstantiatedFromMember, TagDecl *Pattern, TagDecl *PatternDef, TemplateSpecializationKind TSK, bool Complain=true) |
static const Decl * | getCanonicalParmVarDecl (const Decl *D) |
static bool DiagnoseUninstantiableTemplate | ( | Sema & | S, |
SourceLocation | PointOfInstantiation, | ||
TagDecl * | Instantiation, | ||
bool | InstantiatedFromMember, | ||
TagDecl * | Pattern, | ||
TagDecl * | PatternDef, | ||
TemplateSpecializationKind | TSK, | ||
bool | Complain = true |
||
) | [static] |
Determine whether we would be unable to instantiate this template (because it either has no definition, or is in the process of being instantiated).
Definition at line 1879 of file SemaTemplateInstantiate.cpp.
References clang::Sema::Context, clang::Sema::Diag(), clang::Decl::getLocation(), clang::ASTContext::getTypeDeclType(), clang::TagDecl::isBeingDefined(), clang::Decl::isInvalidDecl(), clang::Decl::setInvalidDecl(), clang::TSK_ExplicitInstantiationDeclaration, and clang::TSK_ImplicitInstantiation.
Referenced by clang::Sema::InstantiateClass(), and clang::Sema::InstantiateEnum().
static const Decl* getCanonicalParmVarDecl | ( | const Decl * | D | ) | [static] |
Definition at line 2763 of file SemaTemplateInstantiate.cpp.
References clang::Decl::getCanonicalDecl().
Referenced by clang::LocalInstantiationScope::findInstantiationOf(), clang::LocalInstantiationScope::InstantiatedLocal(), clang::LocalInstantiationScope::InstantiatedLocalPackArg(), and clang::LocalInstantiationScope::MakeInstantiatedLocalArgPack().
static std::pair<unsigned, unsigned> getDepthAndIndex | ( | NamedDecl * | ND | ) | [static] |
Retrieve the depth and index of a parameter pack.
Definition at line 630 of file SemaTemplateInstantiate.cpp.
References clang::TemplateParmPosition::getDepth(), and clang::TemplateParmPosition::getIndex().
static TemplateArgument getPackSubstitutedTemplateArgument | ( | Sema & | S, |
TemplateArgument | Arg | ||
) | [static] |
Definition at line 889 of file SemaTemplateInstantiate.cpp.
References clang::Sema::ArgumentPackSubstitutionIndex, clang::TemplateArgument::getPackExpansionPattern(), clang::TemplateArgument::pack_begin(), and clang::TemplateArgument::pack_size().
static bool NeedsInstantiationAsFunctionType | ( | TypeSourceInfo * | T | ) | [static] |
Definition at line 1550 of file SemaTemplateInstantiate.cpp.
References clang::TypeLoc::castAs(), clang::TypeLoc::getAs(), clang::FunctionTypeLoc::getNumParams(), clang::FunctionTypeLoc::getParam(), clang::TypeSourceInfo::getType(), clang::TypeSourceInfo::getTypeLoc(), clang::DeclaratorDecl::getTypeSourceInfo(), clang::ParmVarDecl::hasDefaultArg(), clang::TypeLoc::IgnoreParens(), clang::Type::isInstantiationDependentType(), clang::Type::isVariablyModifiedType(), and P.
Referenced by clang::Sema::SubstFunctionDeclType().