#include <op.h>
Inherits boost::noncopyable.
Classes | |
struct | context_t |
Public Types | |
enum | kind_t { PLUG , VALUE , IDENT , CONSTANTS , FUNCTION , SCOPE , TERMINALS , O_NOT , O_NEG , UNARY_OPERATORS , O_EQ , O_LT , O_LTE , O_GT , O_GTE , O_AND , O_OR , O_ADD , O_SUB , O_MUL , O_DIV , O_QUERY , O_COLON , O_CONS , O_SEQ , O_DEFINE , O_LOOKUP , O_LAMBDA , O_CALL , O_MATCH , BINARY_OPERATORS , OPERATORS , UNKNOWN , LAST } |
typedef expr_t::ptr_op_t | ptr_op_t |
Static Public Member Functions | |
static ptr_op_t | new_node (kind_t _kind, ptr_op_t _left=NULL, ptr_op_t _right=NULL) |
static ptr_op_t | wrap_functor (expr_t::func_t fobj) |
static ptr_op_t | wrap_scope (shared_ptr< scope_t > sobj) |
static ptr_op_t | wrap_value (const value_t &val) |
Public Attributes | |
kind_t | kind |
Friends | |
class | expr_t |
class | expr_t::parser_t |
void | intrusive_ptr_add_ref (const op_t *op) |
void | intrusive_ptr_release (const op_t *op) |
|
inlineexplicit |
Definition at line 127 of file op.h.
References TRACE_CTOR.
Referenced by new_node().
Definition at line 130 of file op.h.
References TRACE_CTOR.
|
inline |
Definition at line 133 of file op.h.
References assert, and TRACE_DTOR.
|
inline |
Definition at line 184 of file op.h.
References as_function_lval().
|
inline |
Definition at line 180 of file op.h.
References assert, and is_function().
Referenced by as_function().
Definition at line 170 of file op.h.
References as_ident_lval().
|
inline |
Definition at line 166 of file op.h.
References assert, and is_ident().
Referenced by as_ident().
Definition at line 228 of file op.h.
References as_op_lval().
Referenced by has_right(), and right().
|
inline |
Definition at line 201 of file op.h.
References as_scope_lval().
|
inline |
Definition at line 197 of file op.h.
References assert, and is_scope().
Referenced by as_scope().
Definition at line 151 of file op.h.
References as_value_lval().
|
inline |
Definition at line 145 of file op.h.
References assert, ledger::downcast(), is_value(), and VERIFY.
Referenced by as_value().
value_t ledger::expr_t::op_t::calc | ( | scope_t & | scope, |
ptr_op_t * | locus = NULL, | ||
const int | depth = 0 ) |
value_t ledger::expr_t::op_t::call | ( | const value_t & | args, |
scope_t & | scope, | ||
ptr_op_t * | locus = NULL, | ||
const int | depth = 0 ) |
ptr_op_t ledger::expr_t::op_t::compile | ( | scope_t & | scope, |
const int | depth = 0, | ||
scope_t * | param_scope = NULL ) |
|
inline |
|
inline |
Definition at line 177 of file op.h.
References FUNCTION, and kind.
Referenced by as_function_lval().
|
inline |
Definition at line 159 of file op.h.
References assert, IDENT, and kind.
Referenced by as_ident_lval(), and as_op_lval().
|
inline |
Definition at line 191 of file op.h.
Referenced by as_scope_lval(), left(), left(), and set_left().
|
inline |
|
inline |
|
inlinestatic |
Definition at line 321 of file op.h.
References ledger::downcast(), and op_t().
bool ledger::expr_t::op_t::print | ( | std::ostream & | out, |
const context_t & | context = context_t() ) const |
|
inline |
|
inline |
Definition at line 187 of file op.h.
References ledger::downcast().
Definition at line 173 of file op.h.
References ledger::downcast().
Definition at line 204 of file op.h.
References ledger::downcast().
Definition at line 154 of file op.h.
References ledger::downcast(), and VERIFY.
|
inlinestatic |
Definition at line 336 of file op.h.
References ledger::downcast(), and FUNCTION.
|
inlinestatic |
Definition at line 329 of file op.h.
References ledger::downcast(), and VALUE.
|
friend |
kind_t ledger::expr_t::op_t::kind |
Definition at line 125 of file op.h.
Referenced by as_op_lval(), has_right(), is_function(), is_ident(), is_scope(), is_value(), left(), left(), right(), right(), set_left(), and set_right().