On Wed, 30 Mar 2022, Artur T. wrote:
Am 29.03.22 um 19:52 schrieb Allin Cottrell:
> On Tue, 29 Mar 2022, atecon wrote:
>
>> Am 29.03.2022 12:24 schrieb Marcin Błażejowski:
>
> Weird or not, it's now fixed in git.
Hi Allin,
I updated our test suit on this topic and got the following interesting
cases:
<hansl>
matrix m = {1, 4; 2, 5; 3, 6}
eval m[end:end] # "Ambiguous matrix index"
</hansl>
I guess that makes sense and is expected.
Yes, that's a true error, giving a one-dimensional indexation range
for a two-dimensional object.
As for your other cases, good catch! These are now fixed in git: the
ones that should work do work, and the strange ones that shouldn't
work now flag errors.
But I plan to take a deeper look into the relevant code to ensure
that there aren't any other bad cases lurking somewhere. The tricky
thing here is determining unambigously whether an occurrence of
'end' pertains to the row dimension or the column dimension of a
matrix -- even when it's embedded in arithmetic such as "end-1"
and/or wrapped in redundant parentheses as in "(end-1)".
Allin