Mercurial > hg > octave-lojdl
changeset 6416:59a4304b7cc5
[project @ 2007-03-15 20:37:44 by jwe]
author | jwe |
---|---|
date | Thu, 15 Mar 2007 20:37:44 +0000 |
parents | 6b1535a09268 |
children | e25f55e1b226 |
files | src/ChangeLog src/ov-fcn-handle.cc src/variables.cc |
diffstat | 3 files changed, 15 insertions(+), 31 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2007-03-15 John W. Eaton <jwe@octave.org> + + * variables.cc (F__lock_global__): Delete. + 2007-03-14 John W. Eaton <jwe@octave.org> * graphics.cc: New file.
--- a/src/ov-fcn-handle.cc +++ b/src/ov-fcn-handle.cc @@ -698,7 +698,17 @@ if (! error_state && fh) { std::string fh_nm = fh->fcn_name (); - retval = fh_nm; + + if (fh_nm == "@<anonymous>") + { + std::ostringstream buf; + + fh->print_raw (buf); + + retval = buf.str (); + } + else + retval = fh_nm; } else error ("func2str: expecting valid function handle as first argument");
--- a/src/variables.cc +++ b/src/variables.cc @@ -2041,36 +2041,6 @@ return retval; } -DEFUN (__lock_global__, args, , - "-*- texinfo -*-\n\ -@deftypefn {Built-in Function} {} __lock_global__ (@var{name})\n\ -@end deftypefn") -{ - octave_value retval; - - if (args.length () == 1) - { - std::string nm = args(0).string_value (); - - if (! error_state) - { - symbol_record *sr = global_sym_tab->lookup (nm); - - if (sr) - sr->make_eternal (); - else - error ("__lock_global__: %s not found in global symbol table", - nm.c_str ()); - } - else - error ("__lock_global__: expecting argument to be a character string"); - } - else - print_usage (); - - return retval; -} - // Deleting names from the symbol tables. static inline bool