clang API Documentation

Public Member Functions | Static Public Member Functions | Public Attributes
clang::ASTTemplateArgumentListInfo Struct Reference

Represents an explicit template argument list in C++, e.g., the "<int>" in "sort<int>". This is safe to be used inside an AST node, in contrast with TemplateArgumentListInfo. More...

#include <TemplateBase.h>

Inheritance diagram for clang::ASTTemplateArgumentListInfo:
Inheritance graph
[legend]
Collaboration diagram for clang::ASTTemplateArgumentListInfo:
Collaboration graph
[legend]

List of all members.

Public Member Functions

TemplateArgumentLocgetTemplateArgs ()
 Retrieve the template arguments.
const TemplateArgumentLocgetTemplateArgs () const
 Retrieve the template arguments.
const TemplateArgumentLocoperator[] (unsigned I) const
void initializeFrom (const TemplateArgumentListInfo &List)
void initializeFrom (const TemplateArgumentListInfo &List, bool &Dependent, bool &InstantiationDependent, bool &ContainsUnexpandedParameterPack)
void copyInto (TemplateArgumentListInfo &List) const

Static Public Member Functions

static const
ASTTemplateArgumentListInfo
Create (ASTContext &C, const TemplateArgumentListInfo &List)
static std::size_t sizeFor (unsigned NumTemplateArgs)

Public Attributes

SourceLocation LAngleLoc
 The source location of the left angle bracket ('<').
SourceLocation RAngleLoc
 The source location of the right angle bracket ('>').
union {
   unsigned   NumTemplateArgs
 The number of template arguments in TemplateArgs. The actual template arguments (if any) are stored after the ExplicitTemplateArgumentList structure.
   llvm::AlignedCharArray
< llvm::AlignOf
< TemplateArgumentLoc >
::Alignment, 1 >   Aligner
}; 

Detailed Description

Represents an explicit template argument list in C++, e.g., the "<int>" in "sort<int>". This is safe to be used inside an AST node, in contrast with TemplateArgumentListInfo.

Definition at line 564 of file TemplateBase.h.


Member Function Documentation

Retrieve the template arguments.

Definition at line 589 of file TemplateBase.h.

void ASTTemplateArgumentListInfo::initializeFrom ( const TemplateArgumentListInfo List,
bool Dependent,
bool InstantiationDependent,
bool ContainsUnexpandedParameterPack 
)
const TemplateArgumentLoc& clang::ASTTemplateArgumentListInfo::operator[] ( unsigned  I) const [inline]

Definition at line 593 of file TemplateBase.h.

Reimplemented in clang::ASTTemplateKWAndArgsInfo.

Definition at line 560 of file TemplateBase.cpp.

References NumTemplateArgs.

Referenced by Create(), and clang::ASTTemplateKWAndArgsInfo::sizeFor().


Member Data Documentation

union { ... }
llvm::AlignedCharArray< llvm::AlignOf<TemplateArgumentLoc>::Alignment, 1> clang::ASTTemplateArgumentListInfo::Aligner

Force ASTTemplateArgumentListInfo to the right alignment for the following array of TemplateArgumentLocs.

Definition at line 580 of file TemplateBase.h.


The documentation for this struct was generated from the following files: