You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A filter removes elements and a sort discards the original order, so neither can be undone from the output alone.
Decision: decline. Wildcards are index-aligned (element i of a source array is element i of its target array), and that alignment is what makes every wildcard rule invertible. A filter or sort applied to an array two-way rules write would move elements away from the positions those rules decode from, so it would break their inverse silently rather than declare a loss. A filtered or sorted copy written somewhere else is a derived one-way value with an element predicate and a sort key, which is a query rather than a crosswalk rule. The position-preserving form of "only some elements" is per-element when gating (#40), which leaves skipped elements in place.
Revisit if a target format requires a sorted or compacted array as its only representation, with the permutation recorded in the target so decode can restore the original order.
The README reason for this omission is updated in #56.
Declined as recorded: filter and sort break index alignment, which is what makes wildcard rules invertible. Per-element when gating is the position-preserving form.
Activity
Mearman commentedon Oct 21, 2026
Declined as recorded: filter and sort break index alignment, which is what makes wildcard rules invertible. Per-element
whengating is the position-preserving form.