#include "clang/AST/TemplateBase.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/Decl.h"
#include "clang/AST/DeclBase.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/DependenceFlags.h"
#include "clang/AST/Expr.h"
#include "clang/AST/ExprCXX.h"
#include "clang/AST/PrettyPrinter.h"
#include "clang/AST/TemplateName.h"
#include "clang/AST/Type.h"
#include "clang/AST/TypeLoc.h"
#include "clang/Basic/Diagnostic.h"
#include "clang/Basic/LLVM.h"
#include "clang/Basic/LangOptions.h"
#include "clang/Basic/SourceLocation.h"
#include "llvm/ADT/APSInt.h"
#include "llvm/ADT/FoldingSet.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Compiler.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/raw_ostream.h"
#include <cassert>
#include <cstddef>
#include <cstdint>
#include <cstring>
#include <optional>
usingnamespaceclang;
static void printIntegral(const TemplateArgument &TemplArg, raw_ostream &Out,
const PrintingPolicy &Policy, bool IncludeType) { … }
static unsigned getArrayDepth(QualType type) { … }
static bool needsAmpersandOnTemplateArg(QualType paramType, QualType argType) { … }
void TemplateArgument::initFromType(QualType T, bool IsNullPtr,
bool IsDefaulted) { … }
void TemplateArgument::initFromDeclaration(ValueDecl *D, QualType QT,
bool IsDefaulted) { … }
void TemplateArgument::initFromIntegral(const ASTContext &Ctx,
const llvm::APSInt &Value,
QualType Type, bool IsDefaulted) { … }
void TemplateArgument::initFromStructural(const ASTContext &Ctx, QualType Type,
const APValue &V, bool IsDefaulted) { … }
TemplateArgument::TemplateArgument(const ASTContext &Ctx,
const llvm::APSInt &Value, QualType Type,
bool IsDefaulted) { … }
static const ValueDecl *getAsSimpleValueDeclRef(const ASTContext &Ctx,
QualType T, const APValue &V) { … }
TemplateArgument::TemplateArgument(const ASTContext &Ctx, QualType Type,
const APValue &V, bool IsDefaulted) { … }
TemplateArgument
TemplateArgument::CreatePackCopy(ASTContext &Context,
ArrayRef<TemplateArgument> Args) { … }
TemplateArgumentDependence TemplateArgument::getDependence() const { … }
bool TemplateArgument::isDependent() const { … }
bool TemplateArgument::isInstantiationDependent() const { … }
bool TemplateArgument::isPackExpansion() const { … }
bool TemplateArgument::containsUnexpandedParameterPack() const { … }
std::optional<unsigned> TemplateArgument::getNumTemplateExpansions() const { … }
QualType TemplateArgument::getNonTypeTemplateArgumentType() const { … }
void TemplateArgument::Profile(llvm::FoldingSetNodeID &ID,
const ASTContext &Context) const { … }
bool TemplateArgument::structurallyEquals(const TemplateArgument &Other) const { … }
TemplateArgument TemplateArgument::getPackExpansionPattern() const { … }
void TemplateArgument::print(const PrintingPolicy &Policy, raw_ostream &Out,
bool IncludeType) const { … }
SourceRange TemplateArgumentLoc::getSourceRange() const { … }
template <typename T>
static const T &DiagTemplateArg(const T &DB, const TemplateArgument &Arg) { … }
const StreamingDiagnostic &clang::operator<<(const StreamingDiagnostic &DB,
const TemplateArgument &Arg) { … }
clang::TemplateArgumentLocInfo::TemplateArgumentLocInfo(
ASTContext &Ctx, NestedNameSpecifierLoc QualifierLoc,
SourceLocation TemplateNameLoc, SourceLocation EllipsisLoc) { … }
const ASTTemplateArgumentListInfo *
ASTTemplateArgumentListInfo::Create(const ASTContext &C,
const TemplateArgumentListInfo &List) { … }
const ASTTemplateArgumentListInfo *
ASTTemplateArgumentListInfo::Create(const ASTContext &C,
const ASTTemplateArgumentListInfo *List) { … }
ASTTemplateArgumentListInfo::ASTTemplateArgumentListInfo(
const TemplateArgumentListInfo &Info) { … }
ASTTemplateArgumentListInfo::ASTTemplateArgumentListInfo(
const ASTTemplateArgumentListInfo *Info) { … }
void ASTTemplateKWAndArgsInfo::initializeFrom(
SourceLocation TemplateKWLoc, const TemplateArgumentListInfo &Info,
TemplateArgumentLoc *OutArgArray) { … }
void ASTTemplateKWAndArgsInfo::initializeFrom(SourceLocation TemplateKWLoc) { … }
void ASTTemplateKWAndArgsInfo::initializeFrom(
SourceLocation TemplateKWLoc, const TemplateArgumentListInfo &Info,
TemplateArgumentLoc *OutArgArray, TemplateArgumentDependence &Deps) { … }
void ASTTemplateKWAndArgsInfo::copyInto(const TemplateArgumentLoc *ArgArray,
TemplateArgumentListInfo &Info) const { … }