def cmp_eq_pair
import mylsm-lsm-store@0.6.0.1/src/Keys.bend as Keysimport Base
97# `String.eq` is defined by the EQ projection of `String.cmp` (Cmp.is_eq of
98# Pair.snd since bend 2.0.33); matching the handed-back comparison pair
99# exposes that definitional correspondence.
100def cmp_eq_pair(
101 pair: (String & String) & Cmp
102) -> {cmp_is_eq(unpack(pair)) == Cmp.is_eq(Pair.snd(String & String, Cmp, pair)) : Bool}:
103 match pair:
104 case ((a, b), c):
105 match c:
106 case LT{}:
107 {==}
108 case EQ{}:
109 {==}
110 case GT{}:
111 {==}