3 Commits

Author SHA1 Message Date
Zoltan Somogyi
94fadf1797 Add uint versions of array operations.
library/array.m:
    Add uint versions of most of this module's operations.

NEWS.md:
    Mention the new operations.

library/edit_distance.m:
    Use the new array operations to eliminate some casts.

library/edit_seq.m:
    Minor style fix.

tests/hard_coded/array_gen.{m,exp}:
tests/hard_coded/array_test_2.{m,exp}:
    Extend the tests of array.m's operations to the corresponding uint
    versions. Expect the output for the new versions.

tests/hard_coded/array_resize.m:
tests/hard_coded/array_shrink.m:
    Extend the tests of array.m's operations to the corresponding uint
    versions, but generate output only if their results differ from the
    original int versions. (They don't differ.)

tests/hard_coded/array_primitives.m:
    Style fixes.
2026-01-08 03:47:09 +11:00
Zoltan Somogyi
4865f11503 Update programming style. 2020-10-04 13:20:42 +11:00
Julien Fischer
b049a5c3db Fix a problem with array.resize.
array.resize/4 has inconsistent behaviour across backends if its first argument
is negative; make it throw an exception if the first argument is negative.

library/array.m:
    As above.

NEWS:
    Announce the change.

tests/hard_coded/Mmakefile:
tests/hard_coded/array_resize.{m,exp}:
    Add a more extensive test case for array.resize.
2018-11-12 03:52:32 +00:00