bugGNU Octave - Bugs: bug #31397, Load of globals does not give...

 
 

bug #31397: Load of globals does not give access them if they have not been mentioned before

Submitter:  None
Submitted:  Thu 21 Oct 2010 03:13:01 PM UTC
   
 
Category:  Interpreter Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Feature Request
Status:  Fixed Assigned to:  None
Originator Name:  Kim Hansen Originator Email:  -email is unavailable-
Open/Closed:  * Closed Release:  * 3.2.4
Operating System:  * GNU/Linux Fixed Release:  None
Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 21 Oct 2010 07:07:26 PM UTC, comment #1: 

This bug exists in the 3.2.4 code, but was fixed May 13, 2010 in the Mercurial code repository.  To access the fix you will need to build from source using one of the snapshots (such as 3.3.53) or use Mercurial to get the code directly.  Instructions for downloading the code are here (http://www.gnu.org/software/octave/download.html)

Rik <rik5>
Group administrator
Thu 21 Oct 2010 03:13:01 PM UTC, original submission:  

When I load a file with global variables in they are not added to the local list of global variables I have access to. This is a change from octave 3.0.

The example below shows:
  1. I save a global variable called glo in the file called glo.
  2. I load it, but it is not accessible. (this is the bug)
  3. I try to access glo, but it is not defined yet. The I load the file and glo is accessible.


kim@raph:~$ octave -q
octave:1> global glo = 1
octave:2> whos
Variables in the current scope:

  Attr Name        Size                     Bytes  Class
  ==== ====        ====                     =====  =====
       ans         1x30                        30  char
    g  glo         1x1                          8  double

Total is 31 elements using 38 bytes

octave:3> save glo glo
octave:4>
kim@raph:~$ octave -q
octave:1> load glo
octave:2> whos
Variables in the current scope:

  Attr Name        Size                     Bytes  Class
  ==== ====        ====                     =====  =====
       ans         1x30                        30  char

Total is 30 elements using 30 bytes

octave:3>
kim@raph:~$ octave -q
octave:1> glo
error: `glo' undefined near line 1 column 1
octave:1> load glo
octave:2> whos
Variables in the current scope:

  Attr Name        Size                     Bytes  Class
  ==== ====        ====                     =====  =====
       ans         1x30                        30  char
    g  glo         1x1                          8  double

Total is 31 elements using 38 bytes

octave:3>

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by None (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2010-10-21 rik5 StatusNone Fixed
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-caa5.
    Corresponding source code