Fri 24 Jan 2014 12:41:32 PM UTC, original submission:
For the following documented usages, Octave should allow more than 3 arguments:
-- Function File: assert (COND, ERRMSG, ...)
-- Function File: assert (COND, MSG_ID, ERRMSG, ...)
But in 3.8.0 it does not any more:
function assert (cond, varargin)
if (nargin == 0 || nargin > 3)
print_usage ();
endif
- Expected output (Octave 3.6.4):
octave:1> assert(false, '%s%s', 'a', 'b')
error: ab
error: called from:
error: C:\Octave\Octave3.6.4_gcc4.6.2\share\octave\3.6.4\m\testfun\assert.m at line 74, column 9
- Actual output (Octave 3.8.0):
>> assert(false, '%s%s', 'a', 'b')
error: Invalid call to assert. Correct usage is:
[...]
|