Mercurial > hg > octave-nkf
comparison src/pt-stmt.cc @ 3708:9b9efdcbdfd3
[project @ 2000-07-28 20:50:58 by jwe]
author | jwe |
---|---|
date | Fri, 28 Jul 2000 20:53:40 +0000 |
parents | 58140935c812 |
children | bf6116ca10eb |
comparison
equal
deleted
inserted
replaced
3707:58140935c812 | 3708:9b9efdcbdfd3 |
---|---|
94 | 94 |
95 bool pf = silent ? false : print_flag; | 95 bool pf = silent ? false : print_flag; |
96 | 96 |
97 if (cmd || expr) | 97 if (cmd || expr) |
98 { | 98 { |
99 unwind_protect_ptr (curr_statement); | |
100 curr_statement = this; | |
101 | |
99 maybe_echo_code (in_function_body); | 102 maybe_echo_code (in_function_body); |
100 | 103 |
101 if (cmd) | 104 if (cmd) |
102 cmd->eval (); | 105 cmd->eval (); |
103 else | 106 else |
128 retval = expr->rvalue (nargout); | 131 retval = expr->rvalue (nargout); |
129 | 132 |
130 if (do_bind_ans && ! (error_state || retval.empty ())) | 133 if (do_bind_ans && ! (error_state || retval.empty ())) |
131 bind_ans (retval(0), pf); | 134 bind_ans (retval(0), pf); |
132 } | 135 } |
136 | |
137 unwind_protect::run (); | |
133 } | 138 } |
134 | 139 |
135 return retval; | 140 return retval; |
136 } | 141 } |
137 | 142 |
156 if (elt) | 161 if (elt) |
157 { | 162 { |
158 bool silent_flag = | 163 bool silent_flag = |
159 silent ? true : (function_body ? Vsilent_functions : false); | 164 silent ? true : (function_body ? Vsilent_functions : false); |
160 | 165 |
161 unwind_protect_ptr (curr_statement); | |
162 curr_statement = elt; | |
163 | |
164 retval = elt->eval (silent_flag, nargout, function_body); | 166 retval = elt->eval (silent_flag, nargout, function_body); |
165 | |
166 unwind_protect::run (); | |
167 | 167 |
168 if (error_state) | 168 if (error_state) |
169 break; | 169 break; |
170 | 170 |
171 if (tree_break_command::breaking | 171 if (tree_break_command::breaking |