-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
Description
In order to avoid unnecessary calls to unique and sort, it would be a very useful
enhancement if two bits could be added to the array struct (jvp_array), to record whether or not
it is known if (a) (a|sort) is a no-op, and (b) (a|unique) is a no-op.
The main reasons for this request are:
- to allow set-oriented operations to be implemented efficiently using arrays as a backing; and
- to support binary search through arrays if they are known to be sorted.
Optimizing the use of these bits may be difficult, but in my view that should not be a reason not to introduce them with at least minimal support.
Thanks!