v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::Token Class Reference

#include <token.h>

Collaboration diagram for v8::internal::Token:

Public Types

enum  Value : uint8_t { TOKEN_LIST =(T, T) kNumTokens }
 
using IsKeywordBits = base::BitField8<bool, 0, 1>
 
using IsPropertyNameBits = IsKeywordBits::Next<bool, 1>
 

Static Public Member Functions

static const char * Name (Value token)
 
static bool IsKeyword (Value token)
 
static bool IsPropertyName (Value token)
 
static V8_INLINE bool IsValidIdentifier (Value token, LanguageMode language_mode, bool is_generator, bool disallow_await)
 
static bool IsCallable (Value token)
 
static bool IsAutoSemicolon (Value token)
 
static bool IsAnyIdentifier (Value token)
 
static bool IsStrictReservedWord (Value token)
 
static bool IsLiteral (Value token)
 
static bool IsTemplate (Value token)
 
static bool IsMember (Value token)
 
static bool IsProperty (Value token)
 
static bool IsPropertyOrCall (Value token)
 
static bool IsArrowOrAssignmentOp (Value token)
 
static bool IsAssignmentOp (Value token)
 
static bool IsLogicalAssignmentOp (Value token)
 
static bool IsBinaryOp (Value op)
 
static bool IsCompareOp (Value op)
 
static bool IsOrderedRelationalCompareOp (Value op)
 
static bool IsEqualityOp (Value op)
 
static Value BinaryOpForAssignment (Value op)
 
static bool IsBitOp (Value op)
 
static bool IsUnaryOp (Value op)
 
static bool IsCountOp (Value op)
 
static bool IsUnaryOrCountOp (Value op)
 
static bool IsShiftOp (Value op)
 
static const char * String (Value token)
 
static uint8_t StringLength (Value token)
 
static int Precedence (Value token, bool accept_IN)
 

Static Private Attributes

static const char *const name_ [kNumTokens] = {TOKEN_LIST(T, T)}
 
static const char *const string_ [kNumTokens] = {TOKEN_LIST(T, T)}
 
static const uint8_t string_length_ [kNumTokens] = {TOKEN_LIST(T, T)}
 
static const int8_t precedence_ [2][kNumTokens]
 
static const uint8_t token_flags [kNumTokens] = {TOKEN_LIST(KT, KK)}
 

Detailed Description

Definition at line 211 of file token.h.

Member Typedef Documentation

◆ IsKeywordBits

Definition at line 225 of file token.h.

◆ IsPropertyNameBits

Member Enumeration Documentation

◆ Value

Enumerator
TOKEN_LIST 

Definition at line 215 of file token.h.

Member Function Documentation

◆ BinaryOpForAssignment()

static Value v8::internal::Token::BinaryOpForAssignment ( Value op)
inlinestatic

Definition at line 307 of file token.h.

Here is the caller graph for this function:

◆ IsAnyIdentifier()

static bool v8::internal::Token::IsAnyIdentifier ( Value token)
inlinestatic

Definition at line 255 of file token.h.

Here is the caller graph for this function:

◆ IsArrowOrAssignmentOp()

static bool v8::internal::Token::IsArrowOrAssignmentOp ( Value token)
inlinestatic

Definition at line 283 of file token.h.

Here is the caller graph for this function:

◆ IsAssignmentOp()

static bool v8::internal::Token::IsAssignmentOp ( Value token)
inlinestatic

Definition at line 287 of file token.h.

Here is the caller graph for this function:

◆ IsAutoSemicolon()

static bool v8::internal::Token::IsAutoSemicolon ( Value token)
inlinestatic

Definition at line 251 of file token.h.

Here is the caller graph for this function:

◆ IsBinaryOp()

static bool v8::internal::Token::IsBinaryOp ( Value op)
inlinestatic

Definition at line 295 of file token.h.

Here is the caller graph for this function:

◆ IsBitOp()

static bool v8::internal::Token::IsBitOp ( Value op)
inlinestatic

Definition at line 314 of file token.h.

◆ IsCallable()

static bool v8::internal::Token::IsCallable ( Value token)
inlinestatic

Definition at line 247 of file token.h.

Here is the caller graph for this function:

◆ IsCompareOp()

static bool v8::internal::Token::IsCompareOp ( Value op)
inlinestatic

Definition at line 297 of file token.h.

Here is the caller graph for this function:

◆ IsCountOp()

static bool v8::internal::Token::IsCountOp ( Value op)
inlinestatic

Definition at line 319 of file token.h.

Here is the caller graph for this function:

◆ IsEqualityOp()

static bool v8::internal::Token::IsEqualityOp ( Value op)
inlinestatic

Definition at line 303 of file token.h.

Here is the caller graph for this function:

◆ IsKeyword()

static bool v8::internal::Token::IsKeyword ( Value token)
inlinestatic

Definition at line 229 of file token.h.

◆ IsLiteral()

static bool v8::internal::Token::IsLiteral ( Value token)
inlinestatic

Definition at line 263 of file token.h.

Here is the caller graph for this function:

◆ IsLogicalAssignmentOp()

static bool v8::internal::Token::IsLogicalAssignmentOp ( Value token)
inlinestatic

Definition at line 291 of file token.h.

Here is the caller graph for this function:

◆ IsMember()

static bool v8::internal::Token::IsMember ( Value token)
inlinestatic

Definition at line 271 of file token.h.

Here is the caller graph for this function:

◆ IsOrderedRelationalCompareOp()

static bool v8::internal::Token::IsOrderedRelationalCompareOp ( Value op)
inlinestatic

Definition at line 299 of file token.h.

◆ IsProperty()

static bool v8::internal::Token::IsProperty ( Value token)
inlinestatic

Definition at line 275 of file token.h.

Here is the caller graph for this function:

◆ IsPropertyName()

static bool v8::internal::Token::IsPropertyName ( Value token)
inlinestatic

Definition at line 233 of file token.h.

Here is the caller graph for this function:

◆ IsPropertyOrCall()

static bool v8::internal::Token::IsPropertyOrCall ( Value token)
inlinestatic

Definition at line 279 of file token.h.

Here is the caller graph for this function:

◆ IsShiftOp()

static bool v8::internal::Token::IsShiftOp ( Value op)
inlinestatic

Definition at line 323 of file token.h.

◆ IsStrictReservedWord()

static bool v8::internal::Token::IsStrictReservedWord ( Value token)
inlinestatic

Definition at line 259 of file token.h.

Here is the caller graph for this function:

◆ IsTemplate()

static bool v8::internal::Token::IsTemplate ( Value token)
inlinestatic

Definition at line 267 of file token.h.

Here is the caller graph for this function:

◆ IsUnaryOp()

static bool v8::internal::Token::IsUnaryOp ( Value op)
inlinestatic

Definition at line 318 of file token.h.

Here is the caller graph for this function:

◆ IsUnaryOrCountOp()

static bool v8::internal::Token::IsUnaryOrCountOp ( Value op)
inlinestatic

Definition at line 320 of file token.h.

Here is the caller graph for this function:

◆ IsValidIdentifier()

static V8_INLINE bool v8::internal::Token::IsValidIdentifier ( Value token,
LanguageMode language_mode,
bool is_generator,
bool disallow_await )
inlinestatic

Definition at line 237 of file token.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Name()

static const char * v8::internal::Token::Name ( Value token)
inlinestatic

Definition at line 220 of file token.h.

◆ Precedence()

static int v8::internal::Token::Precedence ( Value token,
bool accept_IN )
inlinestatic

Definition at line 340 of file token.h.

Here is the caller graph for this function:

◆ String()

static const char * v8::internal::Token::String ( Value token)
inlinestatic

Definition at line 328 of file token.h.

Here is the caller graph for this function:

◆ StringLength()

static uint8_t v8::internal::Token::StringLength ( Value token)
inlinestatic

Definition at line 333 of file token.h.

Member Data Documentation

◆ name_

const char *const v8::internal::Token::name_ = {TOKEN_LIST(T, T)}
staticprivate

Definition at line 346 of file token.h.

◆ precedence_

const int8_t v8::internal::Token::precedence_
staticprivate
Initial value:
= {{TOKEN_LIST(T1, T1)},
#define T1(name, string, precedence)
Definition token.cc:28
#define T2(name, string, precedence)
Definition token.cc:30

Definition at line 349 of file token.h.

◆ string_

const char *const v8::internal::Token::string_ = {TOKEN_LIST(T, T)}
staticprivate

Definition at line 347 of file token.h.

◆ string_length_

const uint8_t v8::internal::Token::string_length_ = {TOKEN_LIST(T, T)}
staticprivate

Definition at line 348 of file token.h.

◆ token_flags

const uint8_t v8::internal::Token::token_flags = {TOKEN_LIST(KT, KK)}
staticprivate

Definition at line 350 of file token.h.


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