Mercurial > hg > octave-avbm
diff src/symtab.cc @ 9639:8d79f36ebdde
store scope->function pointer
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Mon, 14 Sep 2009 11:23:54 +0200 |
parents | a9b37bae1802 |
children | 633f9d837982 |
line wrap: on
line diff
--- a/src/symtab.cc +++ b/src/symtab.cc @@ -41,7 +41,6 @@ #include "pager.h" #include "parse.h" #include "pt-arg-list.h" -#include "toplev.h" #include "unwind-prot.h" #include "utils.h" #include "debug.h" @@ -535,7 +534,7 @@ scope_val_iterator r = subfunctions.find (xcurrent_scope); - octave_function *curr_fcn = 0; + octave_user_function *curr_fcn = symbol_table::get_curr_fcn (); if (r != subfunctions.end ()) { @@ -545,8 +544,6 @@ } else { - curr_fcn = octave_call_stack::current (); - if (curr_fcn) { scope_id pscope = curr_fcn->parent_fcn_scope (); @@ -567,9 +564,6 @@ // Private function. - if (! curr_fcn) - curr_fcn = octave_call_stack::current (); - if (curr_fcn) { std::string dir_name = curr_fcn->dir_name (); @@ -765,7 +759,7 @@ // Private function. - octave_function *curr_fcn = octave_call_stack::current (); + octave_user_function *curr_fcn = symbol_table::get_curr_fcn (); if (curr_fcn) {