Versions in this module Expand all Collapse all v0 v0.1.0 Mar 18, 2024 Changes in this version + var ErrUnknownComparison = errors.New("unknown comparison") + type CmpResultStore interface + Add func(a, b T, result int) error + Remove func(a, b T) error + type Comparator interface + Compare func(a, b T) (result int, err error) + func JoinComparators[T any](cmps ...Comparator[T]) Comparator[T] + type MemoryStore struct + func (m *MemoryStore[T]) Add(a, b T, result int) error + func (m *MemoryStore[T]) Compare(a, b T) (result int, err error) + func (m *MemoryStore[T]) Remove(a, b T) error + type PullSorter struct + Comparator Comparator[E] + Slice S + Store CmpResultStore[E] + func New[S ~[]E, E comparable](s S) *PullSorter[S, E] + func (p *PullSorter[S, E]) Sort() (sorted S, a, b E, err error)