library/array.m:
The current modes for array.map do not match what the implementation
actually does: specifically, map does not destructively update its
input array argument.
Call unsafe_init/3 in a few spots where it is safe to do so.
tests/hard_coded/ho_array_ops.{m,exp}:
Extend this test to cover array.map.
library/array.m:
Make array.map_corresponding_foldl/6 throw an exception if the input
arrays differ in size. This brings its behaviour into line with that of
the other "corresponding" predicates. It also avoids the unsafe behaviour
that can currently result when the second input array has fewer elements
than the first.
Add some additional modes to array.map_corresponding_foldl/6.
Replace calls to error/1 with calls to unexpected/2 throughout this
module.
NEWS:
Announce the above change.
tests/hard_coded/ho_array_ops.{m,exp}:
Extend this test to cover map_corresponding_foldl/6.
library/array.m:
Add the above predicates.
NEWS:
Announce the additions.
tests/hard_coded/Mmakefile:
tests/hard_coded/ho_array_ops.{m,exp}:
Add tests of the new predicates.