size(cblock,'r'|'c'|'*'|1|2) does not take the option into account
Reported by Samuel GOUGEON (@sgougeon)
BUG DESCRIPTION:
----------------
size(cblock,'r'|'c'|'*'|1|2) does not take the option into account:
--> T = msscanf(-1,["Alain 19";"Pierre 15";"Tom 12"],'%s %d')
T =
Alain 19
Pierre 15
Tom 12
--> size(T) // OK
ans =
3. 2.
--> size(T,"r") // no output : KO
--> size(T,"c") // no output : KO
--> size(T,"*") // no output : KO
--> size(T,1) // no output : KO
--> size(T,2) // no output : KO
--> [m,n]=size(T)
n =
2.
m =
3. 2. // Wrong: 3 expected
In addition, size() of an empty cblock table yields an error:
--> T = mlist('cblock');
--> size(D)
at line 3 of function %cblock_size ( SCI\modules\overloading\macros\%cblock_size.sci line 14 )
in builtin size
Invalid index.
ERROR LOG:
----------
See above
HOW TO REPRODUCE THE BUG:
-------------------------
T = msscanf(-1,["Alain 19";"Pierre 15";"Tom 12"],'%s %d');
size(T)
size(T,1)
size(T,2)
size(T,"r")
size(T,"c")
size(T,"*")
[m,n]=size(T)
T = mlist('cblock');
size(T)
OTHER INFORMATION:
------------------
Same situation in Scilab 6.0.1