Mercurial > octave-nkf
changeset 13709:a0875c6cab7e
error.cc: Don't complain if error struct input is empty (Matlab compatability)
* error.cc (error): Don't complain if error struct input is empty
(Matlab compatability)
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Sun, 16 Oct 2011 13:25:32 -0700 |
parents | ee28bf4c3c29 |
children | 6bd38ab57303 |
files | src/error.cc |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/error.cc Sun Oct 16 13:18:41 2011 -0700 +++ b/src/error.cc Sun Oct 16 13:25:32 2011 -0700 @@ -1062,6 +1062,10 @@ } else if (nargin == 1 && args(0).is_map ()) { + // empty struct is not an error. return and resume calling function. + if (args(0).is_empty ()) + return retval; + octave_value_list tmp; octave_scalar_map m = args(0).scalar_map_value ();