class Token

Declaration

class Token { /* full declaration omitted */ };

Description

Comment token.

Declared at: clang/include/clang/AST/CommentLexer.h:55

Member Variables

private clang::SourceLocation Loc
The location of the token.
private tok::TokenKind Kind
The actual kind of the token.
private unsigned int IntVal
If the token is a known command, contains command ID and TextPtr is unused (command spelling can be found with CommandTraits). Otherwise, contains the length of the string that starts at TextPtr.
private unsigned int Length
Length of the token spelling in comment. Can be 0 for synthenized tokens.
private const char* TextPtr
Contains text value associated with a token.

Method Overview

Methods

void dump(const clang::comments::Lexer& L,
          const clang::SourceManager& SM) const

Declared at: clang/include/clang/AST/CommentLexer.h:216

Parameters

const clang::comments::Lexer& L
const clang::SourceManager& SM

unsigned int getCommandID() const

Declared at: clang/include/clang/AST/CommentLexer.h:120

clang::SourceLocation getEndLocation() const

Declared at: clang/include/clang/AST/CommentLexer.h:83

llvm::StringRef getHTMLIdent() const

Declared at: clang/include/clang/AST/CommentLexer.h:183

llvm::StringRef getHTMLQuotedString() const

Declared at: clang/include/clang/AST/CommentLexer.h:194

llvm::StringRef getHTMLTagEndName() const

Declared at: clang/include/clang/AST/CommentLexer.h:205

llvm::StringRef getHTMLTagStartName() const

Declared at: clang/include/clang/AST/CommentLexer.h:172

tok::TokenKind getKind() const

Declared at: clang/include/clang/AST/CommentLexer.h:89

unsigned int getLength() const

Declared at: clang/include/clang/AST/CommentLexer.h:95

clang::SourceLocation getLocation() const

Declared at: clang/include/clang/AST/CommentLexer.h:80

llvm::StringRef getText() const

Declared at: clang/include/clang/AST/CommentLexer.h:98

llvm::StringRef getUnknownCommandName() const

Declared at: clang/include/clang/AST/CommentLexer.h:109

unsigned int getVerbatimBlockID() const

Declared at: clang/include/clang/AST/CommentLexer.h:130

llvm::StringRef getVerbatimBlockText() const

Declared at: clang/include/clang/AST/CommentLexer.h:140

unsigned int getVerbatimLineID() const

Declared at: clang/include/clang/AST/CommentLexer.h:151

llvm::StringRef getVerbatimLineText() const

Declared at: clang/include/clang/AST/CommentLexer.h:161

bool is(tok::TokenKind K) const

Declared at: clang/include/clang/AST/CommentLexer.h:92

Parameters

tok::TokenKind K

bool isNot(tok::TokenKind K) const

Declared at: clang/include/clang/AST/CommentLexer.h:93

Parameters

tok::TokenKind K

void setCommandID(unsigned int ID)

Declared at: clang/include/clang/AST/CommentLexer.h:125

Parameters

unsigned int ID

void setHTMLIdent(llvm::StringRef Name)

Declared at: clang/include/clang/AST/CommentLexer.h:188

Parameters

llvm::StringRef Name

void setHTMLQuotedString(llvm::StringRef Str)

Declared at: clang/include/clang/AST/CommentLexer.h:199

Parameters

llvm::StringRef Str

void setHTMLTagEndName(llvm::StringRef Name)

Declared at: clang/include/clang/AST/CommentLexer.h:210

Parameters

llvm::StringRef Name

void setHTMLTagStartName(llvm::StringRef Name)

Declared at: clang/include/clang/AST/CommentLexer.h:177

Parameters

llvm::StringRef Name

void setKind(tok::TokenKind K)

Declared at: clang/include/clang/AST/CommentLexer.h:90

Parameters

tok::TokenKind K

void setLength(unsigned int L)

Declared at: clang/include/clang/AST/CommentLexer.h:96

Parameters

unsigned int L

void setLocation(clang::SourceLocation SL)

Declared at: clang/include/clang/AST/CommentLexer.h:81

Parameters

clang::SourceLocation SL

void setText(llvm::StringRef Text)

Declared at: clang/include/clang/AST/CommentLexer.h:103

Parameters

llvm::StringRef Text

void setUnknownCommandName(llvm::StringRef Name)

Declared at: clang/include/clang/AST/CommentLexer.h:114

Parameters

llvm::StringRef Name

void setVerbatimBlockID(unsigned int ID)

Declared at: clang/include/clang/AST/CommentLexer.h:135

Parameters

unsigned int ID

void setVerbatimBlockText(llvm::StringRef Text)

Declared at: clang/include/clang/AST/CommentLexer.h:145

Parameters

llvm::StringRef Text

void setVerbatimLineID(unsigned int ID)

Declared at: clang/include/clang/AST/CommentLexer.h:156

Parameters

unsigned int ID

void setVerbatimLineText(llvm::StringRef Text)

Declared at: clang/include/clang/AST/CommentLexer.h:166

Parameters

llvm::StringRef Text