apjanke / octave-tablicious

Table (relational, tabular data) implementation for GNU Octave
https://apjanke.github.io/octave-tablicious/
GNU General Public License v3.0
28 stars 11 forks source link

Numeric input for string constructor #97

Closed gllmflndn closed 1 year ago

gllmflndn commented 1 year ago

There is an error when the input to the string constructor is a numeric array. The space between num2str and (x) should be removed in {num2str (x)}.

>> string (1)
error: Invalid call to num2str.  Correct usage is:

 -- STR = num2str (X)
 -- STR = num2str (X, PRECISION)
 -- STR = num2str (X, FORMAT)
error: called from
    print_usage at line 105 column 5
    num2str at line 84 column 5
    string>@<anonymous> at line 119 column 49
    string at line 119 column 19
apjanke commented 1 year ago

Nice catch! Looks like it was affecting datetime inputs, too. Fixed in https://github.com/apjanke/octave-tablicious/commit/892f7251d912c0457293e586138e5477c210a422.