Usually calling a Matlab function with an empty comma-separated list is the same as calling it without arguments. For example,
in={}; spy(in{:});
is the same as
spy %// call without inputs
However, I'm getting strange behviour for the 1-output version of toc
: this works as expected
tic; t=toc
whereas this crashes (closes Matlab) in R2015b, Windows 7 64 bits:
tic; in={}; t=toc(in{:})
It works properly in Matlab R2014b, Windows 7 64 bits.
Can someone reproduce this behaviour in R2015b? Any explanation? Possible bug?
Just to close this question:
From the comments above, this problem happens in Matlab R2015b in various operating systems. It doesn't happen in older Matlab versions.
I reported a bug to Mathworks. They told me be the developers are aware of this issue and it will be fixed for R2016b.
EDIT (October 3, 2016): I confirm that the bug has been corrected in R2016b.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With