Skip to content

Commit 7879523

Browse files
authored
Merge pull request #214 from milesfrain/patch-2
Another example for const
2 parents b759878 + 5e4cf10 commit 7879523

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/Data/Function.purs

+6
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@ flip f b a = f a b
2626
-- | ```purescript
2727
-- | const 1 "hello" = 1
2828
-- | ```
29+
-- |
30+
-- | It can also be thought of as creating a function that ignores its argument:
31+
-- |
32+
-- | ```purescript
33+
-- | const 1 = \_ -> 1
34+
-- | ```
2935
const :: forall a b. a -> b -> a
3036
const a _ = a
3137

0 commit comments

Comments
 (0)