Giving tips to help M2SCI...
Name of the declared variable. It can be a Struct field (e.g.
x(1,2).name) or describe the contents of a Cell using syntax
x(1,2).entries.NOTE that for Cells and Structs,
*can be used as an index (see examples below).
Sizes of the variable declared, separated by blanks. Any unknown size can be specified with
?.NOTE that a Matlab character string as defined between single quotes is considered as a vector of characters. Therefore, for instance the size of 'string' is
- data_type & property
data type and property (sub-type) of the variable. Possible values are documented in the Type page.Property values that are not defined as a constant in m2ci -- like 'int8' or 'Axes' -- must be specified without quotes in the m2scideclare statement.
The main difficulty for M2SCI (
mfile2sci) is to find what variables
are: dimensions, type...
To help this tool, just add comments beginning with
the M-file to convert, (
%m2sciassume was used in previous Scilab
versions and is now obsolete).
All data given by
m2scideclare are compared with infered data.
In case of conflict, inferred data are kept and a warning message is displayed.
If you are sure about your data, report a bug.
%m2scideclare var1|2 3|Double|Real
var1 is declared as a 2x3 Double matrix containing real data.
%m2scideclare var2|2 3 10|Double|Complex
var2 is declared as a 2x3x10 Double hypermatrix containing complex data
%m2scideclare var3(1,2).name|1 10|String|?
var3 is declared as a Struct array containing a 1x10 character string in field 'name' of struct at index (1,2)
%m2scideclare var4(1,5).entries|1 ?|Boolean|?
var4 is declared as a Cell containing a row boolean vector at index (1,5)
%m2scideclare var4(1,6).entries|? ?|Int|?
var4 is declared as a Cell containing a row boolean vector at index (1,5) and integer data at index (1,6)
%m2scideclare var5(*,*).name|1 ?|String|?
var5 is declared as a Struct array containing a 1xn character string in all fields 'name'
%m2scideclare var6(2,*).entries|1 3|Double|Real
var6 is declared as a Cell array containing a 1x3 double vector in each element of its second row
- Type — Create a tree containing type inference data
|Report an issue|
|<< About M2SCI tools||Code Matlab => Scilab||mfile2sci >>|