GameApi 28
Library used by GameApi Builder tool
Loading...
Searching...
No Matches
chaiscript::AST_Node Struct Referenceabstract

Struct that doubles as both a parser ast_node and an AST node. More...

#include <chaiscript_common.hpp>

Inheritance diagram for chaiscript::AST_Node:
Collaboration diagram for chaiscript::AST_Node:

Public Member Functions

const std::string & filename () const
const File_Position & start () const
const File_Position & end () const
std::string pretty_print () const
virtual std::vector< std::reference_wrapper< AST_Node > > get_children () const =0
virtual Boxed_Value eval (const chaiscript::detail::Dispatch_State &t_e) const =0
std::string to_string (const std::string &t_prepend="") const
 Prints the contents of an AST node, including its children, recursively.
virtual ~AST_Node ()=default
 AST_Node (AST_Node &&)=default
AST_Node & operator= (AST_Node &&)=default
 AST_Node (const AST_Node &)=delete
AST_Node & operator= (const AST_Node &)=delete

Static Public Member Functions

static bool get_bool_condition (const Boxed_Value &t_bv, const chaiscript::detail::Dispatch_State &t_ss)

Public Attributes

const AST_Node_Type identifier
const std::string text
Parse_Location location

Protected Member Functions

 AST_Node (std::string t_ast_node_text, AST_Node_Type t_id, Parse_Location t_loc)

Detailed Description

Struct that doubles as both a parser ast_node and an AST node.

Constructor & Destructor Documentation

◆ ~AST_Node()

virtual chaiscript::AST_Node::~AST_Node ( )
virtualdefault

◆ AST_Node() [1/3]

chaiscript::AST_Node::AST_Node ( AST_Node && )
default
Here is the caller graph for this function:

◆ AST_Node() [2/3]

chaiscript::AST_Node::AST_Node ( const AST_Node & )
delete

◆ AST_Node() [3/3]

chaiscript::AST_Node::AST_Node ( std::string t_ast_node_text,
AST_Node_Type t_id,
Parse_Location t_loc )
inlineprotected

Member Function Documentation

◆ end()

const File_Position & chaiscript::AST_Node::end ( ) const
inline
Here is the caller graph for this function:

◆ eval()

virtual Boxed_Value chaiscript::AST_Node::eval ( const chaiscript::detail::Dispatch_State & t_e) const
pure virtual

Implemented in chaiscript::eval::AST_Node_Impl< T >.

Here is the caller graph for this function:

◆ filename()

const std::string & chaiscript::AST_Node::filename ( ) const
inline
Here is the caller graph for this function:

◆ get_bool_condition()

bool chaiscript::AST_Node::get_bool_condition ( const Boxed_Value & t_bv,
const chaiscript::detail::Dispatch_State & t_ss )
inlinestatic
Here is the caller graph for this function:

◆ get_children()

virtual std::vector< std::reference_wrapper< AST_Node > > chaiscript::AST_Node::get_children ( ) const
pure virtual

Implemented in chaiscript::eval::AST_Node_Impl< T >.

Here is the caller graph for this function:

◆ operator=() [1/2]

AST_Node & chaiscript::AST_Node::operator= ( AST_Node && )
default

◆ operator=() [2/2]

AST_Node & chaiscript::AST_Node::operator= ( const AST_Node & )
delete

◆ pretty_print()

std::string chaiscript::AST_Node::pretty_print ( ) const
inline
Here is the caller graph for this function:

◆ start()

const File_Position & chaiscript::AST_Node::start ( ) const
inline
Here is the caller graph for this function:

◆ to_string()

std::string chaiscript::AST_Node::to_string ( const std::string & t_prepend = "") const
inline

Prints the contents of an AST node, including its children, recursively.

Here is the caller graph for this function:

Member Data Documentation

◆ identifier

const AST_Node_Type chaiscript::AST_Node::identifier

◆ location

Parse_Location chaiscript::AST_Node::location

◆ text

const std::string chaiscript::AST_Node::text

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