| Safe Haskell | Safe |
|---|---|
| Language | Haskell2010 |
Precursor.Function
Documentation
const x is a unary function which evaluates to x for all inputs.
For instance,
>>>map (const 42) [0..3][42,42,42,42]
is the least fixed point of the function fix ff,
i.e. the least defined x such that f x = x.
flip :: (a -> b -> c) -> b -> a -> c #
takes its (first) two arguments in the reverse order of flip ff.
($) :: (a -> b) -> a -> b infixr 0 #
Application operator. This operator is redundant, since ordinary
application (f x) means the same as (f . However, $ x)$ has
low, right-associative binding precedence, so it sometimes allows
parentheses to be omitted; for example:
f $ g $ h x = f (g (h x))
It is also useful in higher-order situations, such as ,
or map ($ 0) xs.zipWith ($) fs xs