Commit 504c2aeb authored by thomie's avatar thomie

Docs: `sortOn = sortBy (comparing f)` [skip ci]

parent 74a00bc8
......@@ -973,7 +973,7 @@ rqpart cmp x (y:ys) rle rgt r =
-- | Sort a list by comparing the results of a key function applied to each
-- element. @sortOn f@ is equivalent to @sortBy . comparing f@, but has the
-- element. @sortOn f@ is equivalent to @sortBy (comparing f)@, but has the
-- performance advantage of only evaluating @f@ once for each element in the
-- input list. This is called the decorate-sort-undecorate paradigm, or
-- Schwartzian transform.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment