v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
ast.h File Reference
Include dependency graph for ast.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  v8::internal::AstNode
 
class  v8::internal::Statement
 
class  v8::internal::Expression
 
class  v8::internal::FailureExpression
 
class  v8::internal::BreakableStatement
 
class  v8::internal::Block
 
class  v8::internal::Declaration
 
class  v8::internal::VariableDeclaration
 
class  v8::internal::NestedVariableDeclaration
 
class  v8::internal::FunctionDeclaration
 
class  v8::internal::IterationStatement
 
class  v8::internal::DoWhileStatement
 
class  v8::internal::WhileStatement
 
class  v8::internal::ForStatement
 
class  v8::internal::ForEachStatement
 
class  v8::internal::ForInStatement
 
class  v8::internal::ForOfStatement
 
class  v8::internal::ExpressionStatement
 
class  v8::internal::JumpStatement
 
class  v8::internal::ContinueStatement
 
class  v8::internal::BreakStatement
 
class  v8::internal::ReturnStatement
 
class  v8::internal::WithStatement
 
class  v8::internal::CaseClause
 
class  v8::internal::SwitchStatement
 
class  v8::internal::IfStatement
 
class  v8::internal::TryStatement
 
class  v8::internal::TryCatchStatement
 
class  v8::internal::TryFinallyStatement
 
class  v8::internal::DebuggerStatement
 
class  v8::internal::EmptyStatement
 
class  v8::internal::SloppyBlockFunctionStatement
 
class  v8::internal::Literal
 
class  v8::internal::MaterializedLiteral
 
class  v8::internal::RegExpLiteral
 
class  v8::internal::AggregateLiteral
 
class  v8::internal::LiteralBoilerplateBuilder
 
class  v8::internal::LiteralProperty
 
class  v8::internal::ObjectLiteralProperty
 
class  v8::internal::ObjectLiteralBoilerplateBuilder
 
class  v8::internal::ObjectLiteral
 
class  v8::internal::ArrayLiteralBoilerplateBuilder
 
class  v8::internal::ArrayLiteral
 
class  v8::internal::ThisExpression
 
class  v8::internal::VariableProxy
 
struct  v8::internal::VariableProxy::UnresolvedNext
 
class  v8::internal::OptionalChain
 
class  v8::internal::Property
 
class  v8::internal::CallBase
 
class  v8::internal::Call
 
class  v8::internal::CallNew
 
class  v8::internal::SuperCallForwardArgs
 
class  v8::internal::CallRuntime
 
class  v8::internal::UnaryOperation
 
class  v8::internal::BinaryOperation
 
class  v8::internal::NaryOperation
 
struct  v8::internal::NaryOperation::NaryOperationEntry
 
class  v8::internal::CountOperation
 
class  v8::internal::CompareOperation
 
class  v8::internal::Spread
 
class  v8::internal::ConditionalChain
 
struct  v8::internal::ConditionalChain::ConditionalChainEntry
 
class  v8::internal::Conditional
 
class  v8::internal::Assignment
 
class  v8::internal::CompoundAssignment
 
class  v8::internal::Suspend
 
class  v8::internal::Yield
 
class  v8::internal::YieldStar
 
class  v8::internal::Await
 
class  v8::internal::Throw
 
class  v8::internal::FunctionLiteral
 
class  v8::internal::AutoAccessorInfo
 
class  v8::internal::ClassLiteralProperty
 
class  v8::internal::ClassLiteralStaticElement
 
class  v8::internal::InitializeClassMembersStatement
 
class  v8::internal::InitializeClassStaticElementsStatement
 
class  v8::internal::AutoAccessorGetterBody
 
class  v8::internal::AutoAccessorSetterBody
 
class  v8::internal::ClassLiteral
 
class  v8::internal::NativeFunctionLiteral
 
class  v8::internal::SuperPropertyReference
 
class  v8::internal::SuperCallReference
 
class  v8::internal::ImportCallExpression
 
class  v8::internal::EmptyParentheses
 
class  v8::internal::GetTemplateObject
 
class  v8::internal::TemplateLiteral
 
class  v8::internal::AstVisitor< Subclass >
 
class  v8::internal::AstNodeFactory
 

Namespaces

namespace  v8
 
namespace  v8::internal
 

Macros

#define DECLARATION_NODE_LIST(V)
 
#define ITERATION_NODE_LIST(V)
 
#define BREAKABLE_NODE_LIST(V)
 
#define STATEMENT_NODE_LIST(V)
 
#define LITERAL_NODE_LIST(V)
 
#define EXPRESSION_NODE_LIST(V)
 
#define FAILURE_NODE_LIST(V)
 
#define AST_NODE_LIST(V)
 
#define DEF_FORWARD_DECLARATION(type)
 
#define DECLARE_TYPE_ENUM(type)
 
#define DECLARE_NODE_FUNCTIONS(type)
 
#define GENERATE_VISIT_CASE(NodeType)
 
#define GENERATE_FAILURE_CASE(NodeType)
 
#define GENERATE_AST_VISITOR_SWITCH()
 
#define DEFINE_AST_VISITOR_SUBCLASS_MEMBERS()
 
#define DEFINE_AST_VISITOR_MEMBERS_WITHOUT_STACKOVERFLOW()
 
#define STATEMENT_WITH_POSITION(NodeType)
 
#define DECLARE_NODE_FUNCTIONS(type)
 

Enumerations

enum class  v8::internal::IteratorType { v8::internal::kNormal , v8::internal::kAsync }
 
enum class  v8::internal::HoleCheckMode { v8::internal::kRequired , v8::internal::kElided }
 
enum  v8::internal::AssignType {
  v8::internal::NON_PROPERTY , v8::internal::NAMED_PROPERTY , v8::internal::KEYED_PROPERTY , v8::internal::NAMED_SUPER_PROPERTY ,
  v8::internal::KEYED_SUPER_PROPERTY , v8::internal::PRIVATE_METHOD , v8::internal::PRIVATE_GETTER_ONLY , v8::internal::PRIVATE_SETTER_ONLY ,
  v8::internal::PRIVATE_GETTER_AND_SETTER , v8::internal::PRIVATE_DEBUG_DYNAMIC
}
 

Macro Definition Documentation

◆ AST_NODE_LIST

#define AST_NODE_LIST ( V)
Value:
STATEMENT_NODE_LIST(V) \
EXPRESSION_NODE_LIST(V)
#define V(Name)
#define DECLARATION_NODE_LIST(V)
Definition ast.h:45

Definition at line 121 of file ast.h.

◆ BREAKABLE_NODE_LIST

#define BREAKABLE_NODE_LIST ( V)
Value:
V(Block) \
V(SwitchStatement)

Definition at line 56 of file ast.h.

◆ DECLARATION_NODE_LIST

#define DECLARATION_NODE_LIST ( V)
Value:
V(VariableDeclaration) \
V(FunctionDeclaration)

Definition at line 45 of file ast.h.

◆ DECLARE_NODE_FUNCTIONS [1/2]

#define DECLARE_NODE_FUNCTIONS ( type)
Value:
V8_INLINE bool Is##type() const; \
V8_INLINE type* As##type(); \
V8_INLINE const type* As##type() const;
#define V8_INLINE
Definition v8config.h:500
wasm::ValueType type

Definition at line 162 of file ast.h.

◆ DECLARE_NODE_FUNCTIONS [2/2]

#define DECLARE_NODE_FUNCTIONS ( type)
Value:
bool AstNode::Is##type() const { return node_type() == AstNode::k##type; } \
type* AstNode::As##type() { \
return node_type() == AstNode::k##type ? reinterpret_cast<type*>(this) \
: nullptr; \
} \
const type* AstNode::As##type() const { \
return node_type() == AstNode::k##type \
? reinterpret_cast<const type*>(this) \
: nullptr; \
}

Definition at line 162 of file ast.h.

◆ DECLARE_TYPE_ENUM

#define DECLARE_TYPE_ENUM ( type)
Value:
k##type,

Definition at line 147 of file ast.h.

◆ DEF_FORWARD_DECLARATION

#define DEF_FORWARD_DECLARATION ( type)
Value:
class type;

Definition at line 140 of file ast.h.

◆ DEFINE_AST_VISITOR_MEMBERS_WITHOUT_STACKOVERFLOW

#define DEFINE_AST_VISITOR_MEMBERS_WITHOUT_STACKOVERFLOW ( )
Value:
public: \
void Visit(AstNode* node) { GENERATE_AST_VISITOR_SWITCH() } \
\
private:
#define GENERATE_AST_VISITOR_SWITCH()
Definition ast.h:2972

Definition at line 3019 of file ast.h.

◆ DEFINE_AST_VISITOR_SUBCLASS_MEMBERS

#define DEFINE_AST_VISITOR_SUBCLASS_MEMBERS ( )

Definition at line 2978 of file ast.h.

◆ EXPRESSION_NODE_LIST

#define EXPRESSION_NODE_LIST ( V)

Definition at line 84 of file ast.h.

◆ FAILURE_NODE_LIST

#define FAILURE_NODE_LIST ( V)
Value:
V(FailureExpression)

Definition at line 119 of file ast.h.

◆ GENERATE_AST_VISITOR_SWITCH

#define GENERATE_AST_VISITOR_SWITCH ( )
Value:
switch (node->node_type()) { \
AST_NODE_LIST(GENERATE_VISIT_CASE) \
FAILURE_NODE_LIST(GENERATE_FAILURE_CASE) \
}
#define GENERATE_VISIT_CASE(NodeType)
Definition ast.h:2964
#define GENERATE_FAILURE_CASE(NodeType)
Definition ast.h:2968

Definition at line 2972 of file ast.h.

◆ GENERATE_FAILURE_CASE

#define GENERATE_FAILURE_CASE ( NodeType)
Value:
case AstNode::k##NodeType: \
UNREACHABLE();

Definition at line 2968 of file ast.h.

◆ GENERATE_VISIT_CASE

#define GENERATE_VISIT_CASE ( NodeType)
Value:
case AstNode::k##NodeType: \
return this->impl()->Visit##NodeType(static_cast<NodeType*>(node));

Definition at line 2964 of file ast.h.

◆ ITERATION_NODE_LIST

#define ITERATION_NODE_LIST ( V)
Value:
V(DoWhileStatement) \
V(WhileStatement) \
V(ForStatement) \
V(ForInStatement) \
V(ForOfStatement)

Definition at line 49 of file ast.h.

◆ LITERAL_NODE_LIST

#define LITERAL_NODE_LIST ( V)
Value:
V(RegExpLiteral) \
V(ObjectLiteral) \
V(ArrayLiteral)

Definition at line 79 of file ast.h.

◆ STATEMENT_NODE_LIST

#define STATEMENT_NODE_LIST ( V)
Value:
BREAKABLE_NODE_LIST(V) \
V(ExpressionStatement) \
V(EmptyStatement) \
V(SloppyBlockFunctionStatement) \
V(IfStatement) \
V(ContinueStatement) \
V(BreakStatement) \
V(ReturnStatement) \
V(WithStatement) \
V(TryCatchStatement) \
V(TryFinallyStatement) \
V(DebuggerStatement) \
V(InitializeClassMembersStatement) \
V(InitializeClassStaticElementsStatement) \
V(AutoAccessorGetterBody) \
V(AutoAccessorSetterBody)
#define ITERATION_NODE_LIST(V)
Definition ast.h:49

Definition at line 60 of file ast.h.

◆ STATEMENT_WITH_POSITION

#define STATEMENT_WITH_POSITION ( NodeType)
Value:
NodeType* New##NodeType(int pos) { return zone_->New<NodeType>(pos); }
SourcePosition pos
Zone * zone_

Definition at line 3078 of file ast.h.