GNU Octave  4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Member Functions | List of all members
tree_evaluator Class Reference

#include "pt-eval.h"

Inheritance diagram for tree_evaluator:
Inheritance graph
[legend]
Collaboration diagram for tree_evaluator:
Collaboration graph
[legend]

Public Types

typedef void(* decl_elt_init_fcn )(tree_decl_elt &)
 
enum  stmt_list_type { function, script, other }
 

Public Member Functions

 tree_evaluator (void)
 
 ~tree_evaluator (void)
 
void do_unwind_protect_cleanup_code (tree_statement_list *list)
 
void visit_anon_fcn_handle (tree_anon_fcn_handle &)
 
void visit_argument_list (tree_argument_list &)
 
void visit_binary_expression (tree_binary_expression &)
 
void visit_break_command (tree_break_command &)
 
void visit_cell (tree_cell &)
 
virtual void visit_classdef (tree_classdef &)
 
virtual void visit_classdef_attribute (tree_classdef_attribute &)
 
virtual void visit_classdef_attribute_list (tree_classdef_attribute_list &)
 
virtual void visit_classdef_body (tree_classdef_body &)
 
virtual void visit_classdef_enum (tree_classdef_enum &)
 
virtual void visit_classdef_enum_block (tree_classdef_enum_block &)
 
virtual void visit_classdef_enum_list (tree_classdef_enum_list &)
 
virtual void visit_classdef_event (tree_classdef_event &)
 
virtual void visit_classdef_events_block (tree_classdef_events_block &)
 
virtual void visit_classdef_events_list (tree_classdef_events_list &)
 
virtual void visit_classdef_methods_block (tree_classdef_methods_block &)
 
virtual void visit_classdef_methods_list (tree_classdef_methods_list &)
 
virtual void visit_classdef_properties_block (tree_classdef_properties_block &)
 
virtual void visit_classdef_property (tree_classdef_property &)
 
virtual void visit_classdef_property_list (tree_classdef_property_list &)
 
virtual void visit_classdef_superclass (tree_classdef_superclass &)
 
virtual void visit_classdef_superclass_list (tree_classdef_superclass_list &)
 
void visit_colon_expression (tree_colon_expression &)
 
void visit_complex_for_command (tree_complex_for_command &)
 
void visit_constant (tree_constant &)
 
void visit_continue_command (tree_continue_command &)
 
void visit_decl_elt (tree_decl_elt &)
 
void visit_decl_init_list (tree_decl_init_list &)
 
void visit_do_until_command (tree_do_until_command &)
 
void visit_fcn_handle (tree_fcn_handle &)
 
void visit_funcall (tree_funcall &)
 
void visit_function_def (tree_function_def &)
 
void visit_global_command (tree_global_command &)
 
void visit_identifier (tree_identifier &)
 
void visit_if_clause (tree_if_clause &)
 
void visit_if_command (tree_if_command &)
 
void visit_if_command_list (tree_if_command_list &)
 
void visit_index_expression (tree_index_expression &)
 
void visit_matrix (tree_matrix &)
 
void visit_multi_assignment (tree_multi_assignment &)
 
void visit_no_op_command (tree_no_op_command &)
 
void visit_octave_user_function (octave_user_function &)
 
void visit_octave_user_function_header (octave_user_function &)
 
void visit_octave_user_function_trailer (octave_user_function &)
 
void visit_octave_user_script (octave_user_script &)
 
void visit_parameter_list (tree_parameter_list &)
 
void visit_persistent_command (tree_persistent_command &)
 
void visit_postfix_expression (tree_postfix_expression &)
 
void visit_prefix_expression (tree_prefix_expression &)
 
void visit_return_command (tree_return_command &)
 
void visit_return_list (tree_return_list &)
 
void visit_simple_assignment (tree_simple_assignment &)
 
void visit_simple_for_command (tree_simple_for_command &)
 
void visit_statement (tree_statement &)
 
void visit_statement_list (tree_statement_list &)
 
void visit_switch_case (tree_switch_case &)
 
void visit_switch_case_list (tree_switch_case_list &)
 
void visit_switch_command (tree_switch_command &)
 
void visit_try_catch_command (tree_try_catch_command &)
 
void visit_unwind_protect_command (tree_unwind_protect_command &)
 
void visit_while_command (tree_while_command &)
 

Static Public Member Functions

static void reset_debug_state (void)
 
static bool statement_printing_enabled (void)
 

Static Public Attributes

static size_t current_frame = 0
 
static int dbstep_flag = 0
 
static bool debug_mode = false
 
static bool in_loop_command = false
 
static bool quiet_breakpoint_flag = false
 
static stmt_list_type statement_context = tree_evaluator::other
 

Private Member Functions

 tree_evaluator (const tree_evaluator &)
 
void do_breakpoint (tree_statement &stmt) const
 
void do_breakpoint (bool is_breakpoint, bool is_end_of_fcn_or_script=false) const
 
void do_decl_init_list (decl_elt_init_fcn fcn, tree_decl_init_list *init_list)
 
virtual octave_value do_keyboard (const octave_value_list &args=octave_value_list()) const
 
tree_evaluatoroperator= (const tree_evaluator &)
 

Detailed Description

Definition at line 37 of file pt-eval.h.

Member Typedef Documentation

typedef void(* tree_evaluator::decl_elt_init_fcn)(tree_decl_elt &)

Definition at line 43 of file pt-eval.h.

Member Enumeration Documentation

Enumerator
function 
script 
other 

Definition at line 157 of file pt-eval.h.

Constructor & Destructor Documentation

tree_evaluator::tree_evaluator ( void  )
inline

Definition at line 45 of file pt-eval.h.

tree_evaluator::~tree_evaluator ( void  )
inline

Definition at line 47 of file pt-eval.h.

tree_evaluator::tree_evaluator ( const tree_evaluator )
private

Member Function Documentation

void tree_evaluator::do_breakpoint ( tree_statement stmt) const
private
void tree_evaluator::do_breakpoint ( bool  is_breakpoint,
bool  is_end_of_fcn_or_script = false 
) const
private
void tree_evaluator::do_decl_init_list ( decl_elt_init_fcn  fcn,
tree_decl_init_list init_list 
)
private
octave_value tree_evaluator::do_keyboard ( const octave_value_list args = octave_value_list ()) const
privatevirtual

Definition at line 1251 of file pt-eval.cc.

References do_keyboard().

Referenced by do_breakpoint().

void tree_evaluator::do_unwind_protect_cleanup_code ( tree_statement_list list)
tree_evaluator& tree_evaluator::operator= ( const tree_evaluator )
private
void tree_evaluator::reset_debug_state ( void  )
static
bool tree_evaluator::statement_printing_enabled ( void  )
static
void tree_evaluator::visit_anon_fcn_handle ( tree_anon_fcn_handle )
virtual

Implements tree_walker.

Definition at line 78 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_argument_list ( tree_argument_list )
virtual

Implements tree_walker.

Definition at line 84 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_binary_expression ( tree_binary_expression )
virtual

Implements tree_walker.

Definition at line 90 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_break_command ( tree_break_command cmd)
virtual
void tree_evaluator::visit_cell ( tree_cell )
virtual

Implements tree_walker.

Definition at line 601 of file pt-eval.cc.

References panic_impossible.

virtual void tree_walker::visit_classdef ( tree_classdef )
inlinevirtualinherited

Definition at line 267 of file pt-walk.h.

Referenced by tree_classdef::accept().

virtual void tree_walker::visit_classdef_attribute ( tree_classdef_attribute )
inlinevirtualinherited

Definition at line 219 of file pt-walk.h.

Referenced by tree_classdef_attribute::accept().

virtual void tree_walker::visit_classdef_attribute_list ( tree_classdef_attribute_list )
inlinevirtualinherited

Definition at line 222 of file pt-walk.h.

Referenced by tree_classdef_attribute_list::accept().

virtual void tree_walker::visit_classdef_body ( tree_classdef_body )
inlinevirtualinherited

Definition at line 264 of file pt-walk.h.

virtual void tree_walker::visit_classdef_enum ( tree_classdef_enum )
inlinevirtualinherited

Definition at line 255 of file pt-walk.h.

Referenced by tree_classdef_enum::accept().

virtual void tree_walker::visit_classdef_enum_block ( tree_classdef_enum_block )
inlinevirtualinherited

Definition at line 261 of file pt-walk.h.

Referenced by tree_classdef_enum_block::accept().

virtual void tree_walker::visit_classdef_enum_list ( tree_classdef_enum_list )
inlinevirtualinherited

Definition at line 258 of file pt-walk.h.

Referenced by tree_classdef_enum_list::accept().

virtual void tree_walker::visit_classdef_event ( tree_classdef_event )
inlinevirtualinherited

Definition at line 246 of file pt-walk.h.

Referenced by tree_classdef_event::accept().

virtual void tree_walker::visit_classdef_events_block ( tree_classdef_events_block )
inlinevirtualinherited

Definition at line 252 of file pt-walk.h.

Referenced by tree_classdef_events_block::accept().

virtual void tree_walker::visit_classdef_events_list ( tree_classdef_events_list )
inlinevirtualinherited

Definition at line 249 of file pt-walk.h.

Referenced by tree_classdef_events_list::accept().

virtual void tree_walker::visit_classdef_methods_block ( tree_classdef_methods_block )
inlinevirtualinherited

Definition at line 243 of file pt-walk.h.

Referenced by tree_classdef_methods_block::accept().

virtual void tree_walker::visit_classdef_methods_list ( tree_classdef_methods_list )
inlinevirtualinherited

Definition at line 240 of file pt-walk.h.

Referenced by tree_classdef_methods_list::accept().

virtual void tree_walker::visit_classdef_properties_block ( tree_classdef_properties_block )
inlinevirtualinherited

Definition at line 237 of file pt-walk.h.

Referenced by tree_classdef_properties_block::accept().

virtual void tree_walker::visit_classdef_property ( tree_classdef_property )
inlinevirtualinherited

Definition at line 231 of file pt-walk.h.

Referenced by tree_classdef_property::accept().

virtual void tree_walker::visit_classdef_property_list ( tree_classdef_property_list )
inlinevirtualinherited

Definition at line 234 of file pt-walk.h.

Referenced by tree_classdef_property_list::accept().

virtual void tree_walker::visit_classdef_superclass ( tree_classdef_superclass )
inlinevirtualinherited

Definition at line 225 of file pt-walk.h.

Referenced by tree_classdef_superclass::accept().

virtual void tree_walker::visit_classdef_superclass_list ( tree_classdef_superclass_list )
inlinevirtualinherited

Definition at line 228 of file pt-walk.h.

Referenced by tree_classdef_superclass_list::accept().

void tree_evaluator::visit_colon_expression ( tree_colon_expression )
virtual

Implements tree_walker.

Definition at line 110 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_complex_for_command ( tree_complex_for_command cmd)
virtual
void tree_evaluator::visit_constant ( tree_constant )
virtual

Implements tree_walker.

Definition at line 620 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_continue_command ( tree_continue_command cmd)
virtual
void tree_evaluator::visit_decl_elt ( tree_decl_elt )
virtual

Implements tree_walker.

Definition at line 239 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_decl_init_list ( tree_decl_init_list )
virtual

Implements tree_walker.

Definition at line 269 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_do_until_command ( tree_do_until_command cmd)
virtual
void tree_evaluator::visit_fcn_handle ( tree_fcn_handle )
virtual

Implements tree_walker.

Definition at line 626 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_funcall ( tree_funcall )
virtual

Implements tree_walker.

Definition at line 632 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_function_def ( tree_function_def cmd)
virtual
void tree_evaluator::visit_global_command ( tree_global_command cmd)
virtual
void tree_evaluator::visit_identifier ( tree_identifier )
virtual

Implements tree_walker.

Definition at line 538 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_if_clause ( tree_if_clause )
virtual

Implements tree_walker.

Definition at line 544 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_if_command ( tree_if_command cmd)
virtual

Implements tree_walker.

Definition at line 550 of file pt-eval.cc.

References tree_if_command_list::accept(), and tree_if_command::cmd_list().

void tree_evaluator::visit_if_command_list ( tree_if_command_list lst)
virtual
void tree_evaluator::visit_index_expression ( tree_index_expression )
virtual

Implements tree_walker.

Definition at line 589 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_matrix ( tree_matrix )
virtual

Implements tree_walker.

Definition at line 595 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_multi_assignment ( tree_multi_assignment )
virtual

Implements tree_walker.

Definition at line 607 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_no_op_command ( tree_no_op_command cmd)
virtual
void tree_evaluator::visit_octave_user_function ( octave_user_function )
virtual

Implements tree_walker.

Definition at line 500 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_octave_user_function_header ( octave_user_function )

Definition at line 506 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_octave_user_function_trailer ( octave_user_function )

Definition at line 512 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_octave_user_script ( octave_user_script )
virtual

Implements tree_walker.

Definition at line 494 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_parameter_list ( tree_parameter_list )
virtual

Implements tree_walker.

Definition at line 638 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_persistent_command ( tree_persistent_command cmd)
virtual
void tree_evaluator::visit_postfix_expression ( tree_postfix_expression )
virtual

Implements tree_walker.

Definition at line 644 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_prefix_expression ( tree_prefix_expression )
virtual

Implements tree_walker.

Definition at line 650 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_return_command ( tree_return_command cmd)
virtual
void tree_evaluator::visit_return_list ( tree_return_list )
virtual

Implements tree_walker.

Definition at line 679 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_simple_assignment ( tree_simple_assignment )
virtual

Implements tree_walker.

Definition at line 685 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_simple_for_command ( tree_simple_for_command cmd)
virtual
void tree_evaluator::visit_statement ( tree_statement stmt)
virtual
void tree_evaluator::visit_statement_list ( tree_statement_list lst)
virtual
void tree_evaluator::visit_switch_case ( tree_switch_case )
virtual

Implements tree_walker.

Definition at line 833 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_switch_case_list ( tree_switch_case_list )
virtual

Implements tree_walker.

Definition at line 839 of file pt-eval.cc.

References panic_impossible.

void tree_evaluator::visit_switch_command ( tree_switch_command cmd)
virtual
void tree_evaluator::visit_try_catch_command ( tree_try_catch_command cmd)
virtual
void tree_evaluator::visit_unwind_protect_command ( tree_unwind_protect_command cmd)
virtual
void tree_evaluator::visit_while_command ( tree_while_command cmd)
virtual

Member Data Documentation

size_t tree_evaluator::current_frame = 0
static

Definition at line 150 of file pt-eval.h.

Referenced by do_breakpoint(), error_2(), Fkeyboard(), visit_return_command(), and warning_1().

int tree_evaluator::dbstep_flag = 0
static

Definition at line 147 of file pt-eval.h.

Referenced by do_breakpoint(), Fdbstep(), and reset_debug_state().

bool tree_evaluator::debug_mode = false
static
bool tree_evaluator::in_loop_command = false
static
bool tree_evaluator::quiet_breakpoint_flag = false
static

Definition at line 154 of file pt-eval.h.

Referenced by F__db_next_breakpoint_quiet__(), Fkeyboard(), and get_debug_input().

tree_evaluator::stmt_list_type tree_evaluator::statement_context = tree_evaluator::other
static

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