diff src/pt-assign.h @ 8037:0be8cf23b95c

check for obsolete built-in variable assignment at first execution rather than parse time
author Jaroslav Hajek <highegg@gmail.com>
date Tue, 19 Aug 2008 14:09:24 -0400
parents 3100283874d7
children 73c4516fae10
line wrap: on
line diff
--- a/src/pt-assign.h
+++ b/src/pt-assign.h
@@ -47,7 +47,8 @@
 
   tree_simple_assignment (bool plhs = false, int l = -1, int c = -1,
 			  octave_value::assign_op t = octave_value::op_asn_eq)
-    : tree_expression (l, c), lhs (0), rhs (0), preserve (plhs), etype (t) { }
+    : tree_expression (l, c), lhs (0), rhs (0), preserve (plhs), etype (t),
+      first_execution (true) { }
 
   tree_simple_assignment (tree_expression *le, tree_expression *re,
 			  bool plhs = false, int l = -1, int c = -1,
@@ -100,6 +101,9 @@
   // The type of the expression.
   octave_value::assign_op etype;
 
+  // true only on first rvalue() call.
+  bool first_execution;
+
   // No copying!
 
   tree_simple_assignment (const tree_simple_assignment&);
@@ -116,7 +120,8 @@
 
   tree_multi_assignment (bool plhs = false, int l = -1, int c = -1,
 			 octave_value::assign_op t = octave_value::op_asn_eq)
-    : tree_expression (l, c), lhs (0), rhs (0), preserve (plhs), etype(t) { }
+    : tree_expression (l, c), lhs (0), rhs (0), preserve (plhs), etype(t),
+      first_execution (true) { }
 
   tree_multi_assignment (tree_argument_list *lst, tree_expression *r,
 			 bool plhs = false, int l = -1, int c = -1,
@@ -161,6 +166,9 @@
   // The type of the expression.
   octave_value::assign_op etype;
 
+  // true only on first rvalue() call.
+  bool first_execution;
+
   // No copying!
 
   tree_multi_assignment (const tree_multi_assignment&);