fay-base-0.19.4: The base package for Fay.

Data.Ord

Description

Orderings

Synopsis

comparing :: Ord a => (b -> a) -> b -> b -> OrderingSource

comparing p x y = compare (p x) (p y)

Useful combinator for use in conjunction with the xxxBy family of functions from Data.List, for example:

xxxBy

... sortBy (comparing fst) ...