Ord -package:hledger -package:tfp package:linear-base is:exact

Linear Orderings Linear orderings provide a strict order. The laws for (<=) for all <math>:
  • reflexivity: <math>
  • antisymmetry: <math>
  • transitivity: <math>
and these "agree" with <:
  • x <= y = not (y > x)
  • x >= y = not (y < x)
Unlike in the non-linear setting, a linear compare doesn't follow from <= since it requires calls: one to <= and one to ==. However, from a linear compare it is easy to implement the others. Hence, the minimal complete definition only contains compare.