[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #34259] Compatibility: save with empty variabl
From: |
Guillaume |
Subject: |
[Octave-bug-tracker] [bug #34259] Compatibility: save with empty variable names |
Date: |
Fri, 09 Sep 2011 17:00:41 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:6.0) Gecko/20100101 Firefox/6.0 |
URL:
<http://savannah.gnu.org/bugs/?34259>
Summary: Compatibility: save with empty variable names
Project: GNU Octave
Submitted by: gyom
Submitted on: Fri 09 Sep 2011 17:00:40 GMT
Category: None
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Matlab Compatibility
Status: None
Assigned to: None
Originator Name: Guillaume
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: dev
Operating System: GNU/Linux
_______________________________________________________
Details:
There is a small difference in behaviour between Octave and MATLAB when using
'save' with empty variable names or non-existing variables:
In MATLAB:
>> clear
>> a = 1;
>> save('file.mat','a','b')
Error using save
Variable 'b' not found.
>> save('file.mat','a','')
>>
In Octave:
octave> clear
octave> a = 1;
octave> save('file.mat','a','b')
warning: save: no such variable `b'
octave> save('file.mat','a','')
warning: save: no such variable `'
octave>
I.e. Octave returns a warning while MATLAB returns an error for unknown
variables.
Furthermore MATLAB ignores silently an empty variable name while Octave issues
a warning.
I would advocate for a silent execution for the latter as it would allow the
following:
opt = '-mat'; % or '' for no option
save('file.mat','a',opt);
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?34259>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Octave-bug-tracker] [bug #34259] Compatibility: save with empty variable names,
Guillaume <=