octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #58382] Wrong scope when saving variables with


From: Torsten Lilge
Subject: [Octave-bug-tracker] [bug #58382] Wrong scope when saving variables with "Run Selection"
Date: Sun, 17 May 2020 08:50:40 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.162 Safari/537.36

Follow-up Comment #1, bug #58382 (project octave):

I can reproduce the issue, but it also occurs when executing a script file.
When executing


A = 1


in the command line and running a script with 


who
save ("A.mat", "A")


afterwards, the variable "A" is listed by "who" as a variable in the current
scope but "save" fails with the same warning as in your post.

The documentation on script files says: "A script file also differs from a
function file in that the variables named in a script file are not local
variables, but are in the same scope as the other variables that are visible
on the command line."

If I understand this correctly, "who" is behaving like expected, but "save"
does not. 


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?58382>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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