clang 20.0.0git
Public Member Functions | Static Public Member Functions | Public Attributes | Friends | List of all members
clang::ASTTemplateArgumentListInfo Struct Referencefinal

Represents an explicit template argument list in C++, e.g., the "<int>" in "sort<int>". More...

#include "clang/AST/TemplateBase.h"

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

Public Member Functions

SourceLocation getLAngleLoc () const
 
SourceLocation getRAngleLoc () const
 
const TemplateArgumentLocgetTemplateArgs () const
 Retrieve the template arguments.
 
unsigned getNumTemplateArgs () const
 
llvm::ArrayRef< TemplateArgumentLocarguments () const
 
const TemplateArgumentLocoperator[] (unsigned I) const
 

Static Public Member Functions

static const ASTTemplateArgumentListInfoCreate (const ASTContext &C, const TemplateArgumentListInfo &List)
 
static const ASTTemplateArgumentListInfoCreate (const ASTContext &C, const ASTTemplateArgumentListInfo *List)
 

Public Attributes

SourceLocation LAngleLoc
 The source location of the left angle bracket ('<').
 
SourceLocation RAngleLoc
 The source location of the right angle bracket ('>').
 
unsigned NumTemplateArgs
 The number of template arguments in TemplateArgs.
 

Friends

class ASTNodeImporter
 

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 674 of file TemplateBase.h.

Member Function Documentation

◆ arguments()

llvm::ArrayRef< TemplateArgumentLoc > clang::ASTTemplateArgumentListInfo::arguments ( ) const
inline

◆ Create() [1/2]

const ASTTemplateArgumentListInfo * ASTTemplateArgumentListInfo::Create ( const ASTContext C,
const ASTTemplateArgumentListInfo List 
)
static

Definition at line 715 of file TemplateBase.cpp.

References clang::C.

◆ Create() [2/2]

const ASTTemplateArgumentListInfo * ASTTemplateArgumentListInfo::Create ( const ASTContext C,
const TemplateArgumentListInfo List 
)
static

◆ getLAngleLoc()

SourceLocation clang::ASTTemplateArgumentListInfo::getLAngleLoc ( ) const
inline

Definition at line 696 of file TemplateBase.h.

References LAngleLoc.

Referenced by substituteParameterMappings().

◆ getNumTemplateArgs()

unsigned clang::ASTTemplateArgumentListInfo::getNumTemplateArgs ( ) const
inline

Definition at line 703 of file TemplateBase.h.

References NumTemplateArgs.

Referenced by arguments().

◆ getRAngleLoc()

SourceLocation clang::ASTTemplateArgumentListInfo::getRAngleLoc ( ) const
inline

Definition at line 697 of file TemplateBase.h.

References RAngleLoc.

Referenced by clang::ConceptReference::getEndLoc(), and substituteParameterMappings().

◆ getTemplateArgs()

const TemplateArgumentLoc * clang::ASTTemplateArgumentListInfo::getTemplateArgs ( ) const
inline

Retrieve the template arguments.

Definition at line 700 of file TemplateBase.h.

Referenced by clang::ASTRecordWriter::AddASTTemplateArgumentListInfo(), arguments(), and operator[]().

◆ operator[]()

const TemplateArgumentLoc & clang::ASTTemplateArgumentListInfo::operator[] ( unsigned  I) const
inline

Definition at line 709 of file TemplateBase.h.

References getTemplateArgs().

Friends And Related Function Documentation

◆ ASTNodeImporter

friend class ASTNodeImporter
friend

Definition at line 678 of file TemplateBase.h.

Member Data Documentation

◆ LAngleLoc

SourceLocation clang::ASTTemplateArgumentListInfo::LAngleLoc

◆ NumTemplateArgs

unsigned clang::ASTTemplateArgumentListInfo::NumTemplateArgs

◆ RAngleLoc

SourceLocation clang::ASTTemplateArgumentListInfo::RAngleLoc

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