I couldn’t find anything in other prolog implementation yet.
I found this earlier discussion: Selecting a range in a dictionary
which shows that at least rb_visit_range might be more broadly useful than just myself.
N.B.: Sicstus prolog has a predicate called avl_range but the equivalent is rb_values
Yes, I’m confused too as to where ord_lookup should go.
I would slightly favor putting in ordsets as the predicate only advantage over member(K-V, L), K == MyKey is that the list of pairs is sorted, meaning we can unroll the search.