2011-11-24 11:14:45 -08:00
|
|
|
lhs test
|
|
|
|
========
|
2009-02-07 19:20:49 +00:00
|
|
|
|
2011-01-06 16:53:44 -08:00
|
|
|
`unsplit` is an arrow that takes a pair of values and combines them to return
|
|
|
|
a single value:
|
2009-02-07 19:20:49 +00:00
|
|
|
|
2013-12-09 20:31:47 -08:00
|
|
|
``` {.sourceCode .literate .haskell}
|
2011-01-06 16:53:44 -08:00
|
|
|
unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
2013-01-26 16:09:41 -08:00
|
|
|
unsplit = arr . uncurry
|
|
|
|
-- arr (\op (x,y) -> x `op` y)
|
2013-12-09 20:31:47 -08:00
|
|
|
```
|
2009-02-07 19:20:49 +00:00
|
|
|
|
2011-01-06 16:53:44 -08:00
|
|
|
`(***)` combines two arrows into a new arrow by running the two arrows on a
|
|
|
|
pair of values (one arrow on the first item of the pair and one arrow on the
|
|
|
|
second item of the pair).
|
2009-02-07 19:20:49 +00:00
|
|
|
|
|
|
|
f *** g = first f >>> second g
|
|
|
|
|
2009-02-14 04:08:18 +00:00
|
|
|
Block quote:
|
|
|
|
|
|
|
|
> foo bar
|