#include "pt-exp.h"
Public Member Functions | |
tree_expression (int l=-1, int c=-1) | |
virtual | ~tree_expression ()=default |
virtual void | copy_base (const tree_expression &e) |
virtual tree_expression * | dup (symbol_scope &scope) const =0 |
virtual octave_value | evaluate (tree_evaluator &tw, int nargout=1)=0 |
virtual octave_value_list | evaluate_n (tree_evaluator &tw, int nargout=1)=0 |
virtual bool | is_assignment_expression () const |
virtual bool | is_binary_expression () const |
virtual bool | is_boolean_expression () const |
virtual bool | is_colon_expression () const |
virtual bool | is_constant () const |
bool | is_for_cmd_expr () const |
virtual bool | is_identifier () const |
virtual bool | is_index_expression () const |
virtual bool | is_matrix () const |
bool | is_postfix_indexed () const |
virtual bool | is_prefix_expression () const |
virtual bool | is_unary_expression () const |
virtual bool | iscell () const |
virtual octave_lvalue | lvalue (tree_evaluator &) |
virtual bool | lvalue_ok () const |
void | mark_as_for_cmd_expr () |
tree_expression * | mark_in_parens () |
virtual std::string | name () const |
virtual std::string | oper () const |
virtual std::string | original_text () const |
int | paren_count () const |
char | postfix_index () const |
bool | print_result () const |
virtual bool | rvalue_ok () const |
tree_expression * | set_postfix_index (char type) |
tree_expression * | set_print_flag (bool print) |
Public Member Functions inherited from tree | |
tree (int l=-1, int c=-1) | |
virtual | ~tree ()=default |
virtual void | accept (tree_walker &tw)=0 |
const std::string | bp_cond () const |
virtual int | column () const |
void | column (int c) |
virtual void | delete_breakpoint () |
bool | is_active_breakpoint (tree_evaluator &tw) const |
bool | is_breakpoint () const |
virtual int | line () const |
void | line (int l) |
bool | meets_bp_condition (tree_evaluator &tw) const |
virtual void | set_breakpoint (const std::string &condition) |
void | set_location (int l, int c) |
std::string | str_print_code () |
Protected Attributes | |
bool | m_for_cmd_expr |
int | m_num_parens |
char | m_postfix_index_type |
bool | m_print_flag |
|
inline |
|
virtualdefault |
|
inlinevirtual |
Definition at line 128 of file pt-exp.h.
References m_num_parens, m_postfix_index_type, and m_print_flag.
Referenced by tree_array_list::copy_base(), tree_simple_assignment::dup(), tree_binary_expression::dup(), tree_braindead_shortcircuit_binary_expression::dup(), tree_boolean_expression::dup(), tree_superclass_ref::dup(), tree_metaclass_query::dup(), tree_colon_expression::dup(), tree_constant::dup(), tree_fcn_handle::dup(), tree_anon_fcn_handle::dup(), tree_identifier::dup(), tree_index_expression::dup(), tree_prefix_expression::dup(), and tree_postfix_expression::dup().
|
pure virtual |
Implemented in tree_postfix_expression, tree_prefix_expression, tree_matrix, tree_index_expression, tree_identifier, tree_anon_fcn_handle, tree_fcn_handle, tree_constant, tree_colon_expression, tree_metaclass_query, tree_superclass_ref, tree_cell, tree_boolean_expression, tree_braindead_shortcircuit_binary_expression, tree_binary_expression, tree_multi_assignment, tree_simple_assignment, tree_array_list, and tree_black_hole.
Referenced by tree_argument_list::dup(), tree_simple_assignment::dup(), tree_binary_expression::dup(), tree_braindead_shortcircuit_binary_expression::dup(), tree_boolean_expression::dup(), tree_colon_expression::dup(), tree_decl_elt::dup(), tree_anon_fcn_handle::dup(), tree_index_expression::dup(), tree_prefix_expression::dup(), tree_postfix_expression::dup(), and tree_evaluator::evaluate_anon_fcn_handle().
|
pure virtual |
Implemented in tree_index_expression, tree_identifier, tree_anon_fcn_handle, tree_fcn_handle, tree_superclass_ref, tree_multi_assignment, tree_simple_assignment, tree_postfix_expression, tree_prefix_expression, tree_matrix, tree_constant, tree_colon_expression, tree_metaclass_query, tree_cell, tree_compound_binary_expression, tree_boolean_expression, tree_braindead_shortcircuit_binary_expression, and tree_binary_expression.
Referenced by tree_evaluator::eval_decl_elt(), tree_binary_expression::evaluate(), tree_braindead_shortcircuit_binary_expression::evaluate(), tree_boolean_expression::evaluate(), tree_compound_binary_expression::evaluate(), tree_colon_expression::evaluate(), tree_prefix_expression::evaluate(), tree_postfix_expression::evaluate(), tree_simple_assignment::evaluate(), tree_index_expression::evaluate_n(), base_parser::finish_array_list(), tree_index_expression::get_struct_index(), tree_evaluator::switch_case_label_matches(), base_parser::validate_matrix_for_assignment(), tree_evaluator::visit_complex_for_command(), tree_evaluator::visit_decl_elt(), tree_evaluator::visit_simple_for_command(), tree_evaluator::visit_statement(), and tree_evaluator::visit_switch_command().
|
pure virtual |
Implemented in tree_postfix_expression, tree_prefix_expression, tree_matrix, tree_index_expression, tree_identifier, tree_anon_fcn_handle, tree_fcn_handle, tree_constant, tree_colon_expression, tree_metaclass_query, tree_superclass_ref, tree_cell, tree_compound_binary_expression, tree_boolean_expression, tree_binary_expression, tree_multi_assignment, and tree_simple_assignment.
Referenced by tree_evaluator::eval_string(), and tree_multi_assignment::evaluate_n().
|
inlinevirtual |
Reimplemented in tree_multi_assignment, and tree_simple_assignment.
Definition at line 70 of file pt-exp.h.
Referenced by bp_table::condition_valid(), tree_evaluator::eval_string(), and tree_evaluator::visit_statement().
|
inlinevirtual |
Reimplemented in tree_binary_expression.
Definition at line 76 of file pt-exp.h.
Referenced by base_parser::maybe_convert_to_braindead_shortcircuit().
|
inlinevirtual |
Reimplemented in tree_boolean_expression.
|
inlinevirtual |
Reimplemented in tree_colon_expression.
|
inlinevirtual |
Reimplemented in tree_constant.
Definition at line 60 of file pt-exp.h.
Referenced by tree_argument_list::all_elements_are_constant(), base_parser::make_colon_expression(), and base_parser::validate_matrix_for_assignment().
|
inline |
Definition at line 108 of file pt-exp.h.
References m_for_cmd_expr.
Referenced by tree_colon_expression::evaluate().
|
inlinevirtual |
Reimplemented in tree_identifier.
Definition at line 66 of file pt-exp.h.
Referenced by tree_argument_list::append(), tree_evaluator::eval_string(), tree_index_expression::evaluate_n(), tree_evaluator::is_defined(), tree_argument_list::is_valid_lvalue_list(), tree_evaluator::is_variable(), base_parser::make_assign_op(), base_parser::make_try_command(), tree_argument_list::variable_names(), and tree_evaluator::visit_statement().
|
inlinevirtual |
Reimplemented in tree_index_expression.
Definition at line 68 of file pt-exp.h.
Referenced by tree_argument_list::is_valid_lvalue_list(), base_parser::make_assign_op(), base_parser::make_index_expression(), base_parser::make_indirect_ref(), and tree_argument_list::variable_names().
|
inlinevirtual |
Reimplemented in tree_matrix.
Definition at line 62 of file pt-exp.h.
Referenced by base_parser::validate_array_list(), and base_parser::validate_matrix_for_assignment().
|
inline |
Definition at line 90 of file pt-exp.h.
References m_postfix_index_type.
Referenced by tree_superclass_ref::evaluate_n(), tree_identifier::evaluate_n(), base_parser::make_index_expression(), and base_parser::make_indirect_ref().
|
inlinevirtual |
|
inlinevirtual |
Reimplemented in tree_unary_expression.
|
inlinevirtual |
|
virtual |
Reimplemented in tree_index_expression, tree_black_hole, and tree_identifier.
Definition at line 43 of file pt-exp.cc.
References error().
Referenced by tree_prefix_expression::evaluate(), tree_postfix_expression::evaluate(), tree_simple_assignment::evaluate(), tree_index_expression::lvalue(), tree_evaluator::visit_complex_for_command(), and tree_evaluator::visit_simple_for_command().
|
inlinevirtual |
Reimplemented in tree_index_expression, and tree_identifier.
Definition at line 82 of file pt-exp.h.
Referenced by tree_index_expression::lvalue_ok(), tree_checker::visit_argument_list(), tree_checker::visit_simple_assignment(), and tree_checker::visit_simple_for_command().
|
inline |
Definition at line 106 of file pt-exp.h.
References m_for_cmd_expr.
Referenced by base_parser::make_for_command().
|
inline |
Definition at line 110 of file pt-exp.h.
References m_num_parens.
|
inlinevirtual |
Reimplemented in tree_index_expression, tree_black_hole, tree_identifier, and tree_fcn_handle.
Definition at line 102 of file pt-exp.h.
Referenced by tree_simple_assignment::evaluate(), tree_multi_assignment::evaluate_n(), tree_evaluator::final_index_error(), base_parser::make_assign_op(), base_parser::make_for_command(), and tree_index_expression::name().
|
inlinevirtual |
Reimplemented in tree_unary_expression, tree_boolean_expression, tree_binary_expression, tree_multi_assignment, and tree_simple_assignment.
Definition at line 100 of file pt-exp.h.
Referenced by error().
|
virtual |
Reimplemented in tree_constant.
|
inline |
Definition at line 88 of file pt-exp.h.
References m_num_parens.
Referenced by tree_print_code::visit_index_expression().
|
inline |
Definition at line 93 of file pt-exp.h.
References m_postfix_index_type.
Referenced by tree_identifier::evaluate_n().
|
inline |
Definition at line 98 of file pt-exp.h.
References m_print_flag.
Referenced by tree_evaluator::eval_string(), tree_simple_assignment::evaluate(), tree_multi_assignment::evaluate_n(), tree_identifier::evaluate_n(), tree_statement::print_result(), and tree_evaluator::visit_statement().
|
inlinevirtual |
Reimplemented in tree_postfix_expression, tree_prefix_expression, tree_matrix, tree_index_expression, tree_anon_fcn_handle, tree_fcn_handle, tree_constant, tree_colon_expression, tree_cell, tree_compound_binary_expression, tree_boolean_expression, tree_binary_expression, tree_multi_assignment, and tree_simple_assignment.
|
inline |
Definition at line 116 of file pt-exp.h.
References m_postfix_index_type.
Referenced by base_parser::make_index_expression(), and base_parser::make_indirect_ref().
|
inline |
Definition at line 122 of file pt-exp.h.
References m_print_flag.
Referenced by tree_evaluator::eval_string(), base_parser::make_anon_fcn_handle(), and tree_statement::set_print_flag().
|
protected |
Definition at line 157 of file pt-exp.h.
Referenced by is_for_cmd_expr(), and mark_as_for_cmd_expr().
|
protected |
Definition at line 148 of file pt-exp.h.
Referenced by copy_base(), mark_in_parens(), and paren_count().
|
protected |
Definition at line 153 of file pt-exp.h.
Referenced by copy_base(), is_postfix_indexed(), postfix_index(), and set_postfix_index().
|
protected |
Definition at line 160 of file pt-exp.h.
Referenced by copy_base(), print_result(), and set_print_flag().