def unique.le

bend-kit-json@0.7.0.0 · json.bend:767

import bend-kit-json@0.7.0.0/json.bend as Json
import Base

767# Lexicographic order on fingerprints.
768def unique.le(a: List<&2, U32>, b: List<&2, U32>) -> Bool:
769  match a b:
770    case Nil{} Nil{}:
771      True{}
772    case Nil{} y <> yt:
773      True{}
774    case x <> xt Nil{}:
775      False{}
776    case +x <> xt +y <> yt:
777      Bool.or(U32.is_lt(x, y), Bool.and(U32.is_eq(x, y), unique.le(xt, yt)))

Uses (7)

Used by (2)