Instances2Eval
type Eval (ListCmpFnd '[]) = 'EQDefined in fcf-containers-0.8.2 · Fcf.Alg.Sorttype Eval (ListCmpFnd (a ': as)) = Eval (If (Eval (TyEq a 'EQ)) (ListCmpFnd as) (Pure a))Defined in fcf-containers-0.8.2 · Fcf.Alg.Sort
:: a typeCtrl KGHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05
Modulefcf-containers-0.8.2Haskell2010
type Eval (ListCmpFnd '[]) = 'EQDefined in fcf-containers-0.8.2 · Fcf.Alg.Sorttype Eval (ListCmpFnd (a ': as)) = Eval (If (Eval (TyEq a 'EQ)) (ListCmpFnd as) (Pure a))Defined in fcf-containers-0.8.2 · Fcf.Alg.SortCompare lists with the given comparison for the elements.
Give true if the first list is before the second, given the comparison function for the elements.
Comparison for the Nats.
TODO: Would this fit to Fcf.Data.Nat on first-class-families?
Comparison for Symbol lists.
Useful when sorting with Qsort.
type Eval (SymbolListOrd as bs) = Eval (ListOrd SymbolOrd as bs)Defined in fcf-containers-0.8.2 · Fcf.Alg.SortComparison for Nat lists.
Useful when sorting with Qsort.
type Eval (NatListOrd as bs) = Eval (ListOrd NatOrd as bs)Defined in fcf-containers-0.8.2 · Fcf.Alg.SortQsort - give the comparison function a -> a -> Exp Bool comparing your
list elements and then Qsort will order the list.
Example
:kind! Eval (Qsort (N.<) '[5,3,1,9,4,6,3])Eval (Qsort (N.<) '[5,3,1,9,4,6,3]) :: [TL.Natural] = '[1, 3, 3, 4, 5, 6, 9]
:kind! Eval (Qsort (S.<) '[ "bb", "e", "a", "e", "d" ])Eval (Qsort (S.<) '[ "bb", "e", "a", "e", "d" ]) :: [Symbol] = '["a", "bb", "d", "e", "e"]