I am trying to define a 2D matrix using the literal notation:
m = [a b; c d]
...but where the elements can be long function calls for example:
m = [
my_long_function_call(with, many, arguments, even="optional",
ones=true)
my_long_function_call(with, many, arguments, even="optional",
ones=true);
my_long_function_call(with, many, arguments, even="optional", ones=true)
my_long_function_call(with, many, arguments, even="optional",
ones=true);
]
the problem is it seems like the newline is treated differently than
regular white-space and is incompatible with the semi-colon. In fact
(though not documented as for as I could tell) the following also builds a
matrix:
m = [
a b
c d
]
Is there a plan for the long term behavior of this? It seems to me that the
slight gain in cleanliness by allowing the semi-colons to be dropped is
outweighed by the inability to use the syntax for longer terms.
Obviously this is not a huge issue and there are many ways to build these
arrays, I just ask because I am trying to decide on a function interface
for a library.
Thanks,
Scott