help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Global functions taking precedence over subfunctions


From: John W. Eaton
Subject: Re: Global functions taking precedence over subfunctions
Date: Fri, 2 Sep 2005 02:28:41 -0400

On  2-Sep-2005, Rafael Laboissiere wrote:

| * John W. Eaton <address@hidden> [2005-09-01 21:53]:
| 
| > No, it's a bug.
| > 
| > Please try the following patch.  This diff is relative to the current
| > CVS.  The patch for 2.1.x is similar.
| 
| Sorry, there was no patch attached to your message.

Oops.  Here is the patch.

jwe


src/ChangeLog:

2005-09-01  John W. Eaton  <address@hidden>

        * variables.cc (symbol_out_of_date): Don't check nested functions.


Index: src/variables.cc
===================================================================
RCS file: /cvs/octave/src/variables.cc,v
retrieving revision 1.269
diff -u -r1.269 variables.cc
--- src/variables.cc    17 Jun 2005 07:52:28 -0000      1.269
+++ src/variables.cc    2 Sep 2005 01:48:54 -0000
@@ -1008,7 +1008,12 @@
 
       octave_function *fcn = ans.function_value (true);
 
-      if (fcn)
+      // No need to check nested functions.  They can only be executed
+      // from within the parent function that contains them.  Parent
+      // and nested functions will be updated simultaneously when we
+      // check the parent.
+
+      if (fcn && ! fcn->is_nested_function ())
        {
          std::string ff = fcn->fcn_file_name ();
 



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]