diff src/variables.cc @ 5930:a703198cb8b8

[project @ 2006-08-15 06:06:15 by jwe]
author jwe
date Tue, 15 Aug 2006 06:06:16 +0000
parents e6c29de3be38
children c9f0839c583f
line wrap: on
line diff
--- a/src/variables.cc	Mon Aug 14 20:07:37 2006 +0000
+++ b/src/variables.cc	Tue Aug 15 06:06:16 2006 +0000
@@ -706,20 +706,8 @@
   return retval;
 }
 
-DEFUN (isglobal, args, ,
-  "-*- texinfo -*-\n\
-@deftypefn {Built-in Function} {} isglobal (@var{name})\n\
-Return 1 if @var{name} is globally visible.  Otherwise, return 0.  For\n\
-example,\n\
-\n\
-@example\n\
-@group\n\
-global x\n\
-isglobal (\"x\")\n\
-     @result{} 1\n\
-@end group\n\
-@end example\n\
-@end deftypefn")
+static octave_value
+do_isglobal (const octave_value_list& args)
 {
   octave_value retval = false;
 
@@ -746,6 +734,33 @@
   return retval;
 }
 
+DEFUN (isglobal, args, ,
+  "-*- texinfo -*-\n\
+@deftypefn {Built-in Function} {} isglobal (@var{name})\n\
+Return 1 if @var{name} is globally visible.  Otherwise, return 0.  For\n\
+example,\n\
+\n\
+@example\n\
+@group\n\
+global x\n\
+isglobal (\"x\")\n\
+     @result{} 1\n\
+@end group\n\
+@end example\n\
+@end deftypefn")
+{
+  return do_isglobal (args);
+}
+
+DEFUN (is_global, args, ,
+  "-*- texinfo -*-\n\
+@deftypefn {Built-in Function} {} isglobal (@var{name})\n\
+This function has been deprecated.  Use isglobal instead.\n\
+@end deftypefn")
+{
+  return do_isglobal (args);
+}
+
 int
 symbol_exist (const std::string& name, const std::string& type)
 {