Mercurial > octave
changeset 23523:d2748870db4e
undo part of previous change
* pt-binop.h (tree_binary_expression::lhs,
tree_binary_expression::rhs): Undo previous change.
* pt-cbinop.h (tree_compound_binary_expression::clhs,
tree_compound_binary_expression::crhs): Rename from lhs and rhs.
* pt-eval.cc (tree_evaluator::visit_compound_binary_expression): Use
clhs and crhs methods to access transformed operands.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Tue, 23 May 2017 14:27:44 -0400 |
parents | d2e300f7700c |
children | 7c278572db66 |
files | libinterp/parse-tree/pt-binop.h libinterp/parse-tree/pt-cbinop.h libinterp/parse-tree/pt-eval.cc |
diffstat | 3 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/parse-tree/pt-binop.h Tue May 23 13:55:43 2017 -0400 +++ b/libinterp/parse-tree/pt-binop.h Tue May 23 14:27:44 2017 -0400 @@ -95,8 +95,8 @@ octave_value::binary_op op_type (void) const { return etype; } - virtual tree_expression * lhs (void) { return op_lhs; } - virtual tree_expression * rhs (void) { return op_rhs; } + tree_expression * lhs (void) { return op_lhs; } + tree_expression * rhs (void) { return op_rhs; } bool is_eligible_for_braindead_shortcircuit (void) const {
--- a/libinterp/parse-tree/pt-cbinop.h Tue May 23 13:55:43 2017 -0400 +++ b/libinterp/parse-tree/pt-cbinop.h Tue May 23 14:27:44 2017 -0400 @@ -55,8 +55,8 @@ bool rvalue_ok (void) const { return true; } - tree_expression * lhs (void) { return cop_lhs; } - tree_expression * rhs (void) { return cop_rhs; } + tree_expression * clhs (void) { return cop_lhs; } + tree_expression * crhs (void) { return cop_rhs; } void accept (tree_walker& tw) {
--- a/libinterp/parse-tree/pt-eval.cc Tue May 23 13:55:43 2017 -0400 +++ b/libinterp/parse-tree/pt-eval.cc Tue May 23 14:27:44 2017 -0400 @@ -286,13 +286,13 @@ { octave_value val; - tree_expression *op_lhs = expr.lhs (); + tree_expression *op_lhs = expr.clhs (); if (op_lhs) { octave_value a = evaluate (op_lhs); - tree_expression *op_rhs = expr.rhs (); + tree_expression *op_rhs = expr.crhs (); if (a.is_defined () && op_rhs) {