LHS test changes for new wrapping & highlighting-kate version.
This commit is contained in:
parent
c4c336460b
commit
71bedab81c
8 changed files with 69 additions and 34 deletions
|
@ -6,9 +6,21 @@
|
||||||
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
||||||
><pre class="sourceCode haskell"
|
><pre class="sourceCode haskell"
|
||||||
><code
|
><code
|
||||||
>> unsplit :: (<span class="dt"
|
>> <span class="ot"
|
||||||
|
>unsplit </span
|
||||||
|
><span class="ot"
|
||||||
|
>::</span
|
||||||
|
> (<span class="dt"
|
||||||
>Arrow</span
|
>Arrow</span
|
||||||
> a) => (b -> c -> d) -> a (b, c) d<br
|
> a) <span class="ot"
|
||||||
|
>=></span
|
||||||
|
> (b <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> c <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> d) <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> a (b, c) d<br
|
||||||
/>> unsplit <span class="fu"
|
/>> unsplit <span class="fu"
|
||||||
>=</span
|
>=</span
|
||||||
> arr <span class="fu"
|
> arr <span class="fu"
|
||||||
|
|
|
@ -33,9 +33,21 @@ pre.sourceCode span.er { color: red; font-weight: bold; }
|
||||||
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
||||||
><pre class="sourceCode haskell"
|
><pre class="sourceCode haskell"
|
||||||
><code
|
><code
|
||||||
>unsplit :: (<span class="dt"
|
><span class="ot"
|
||||||
|
>unsplit </span
|
||||||
|
><span class="ot"
|
||||||
|
>::</span
|
||||||
|
> (<span class="dt"
|
||||||
>Arrow</span
|
>Arrow</span
|
||||||
> a) => (b -> c -> d) -> a (b, c) d<br
|
> a) <span class="ot"
|
||||||
|
>=></span
|
||||||
|
> (b <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> c <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> d) <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> a (b, c) d<br
|
||||||
/>unsplit <span class="fu"
|
/>unsplit <span class="fu"
|
||||||
>=</span
|
>=</span
|
||||||
> arr <span class="fu"
|
> arr <span class="fu"
|
||||||
|
|
|
@ -33,9 +33,21 @@ pre.sourceCode span.er { color: red; font-weight: bold; }
|
||||||
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
> is an arrow that takes a pair of values and combines them to return a single value:</p
|
||||||
><pre class="sourceCode haskell"
|
><pre class="sourceCode haskell"
|
||||||
><code
|
><code
|
||||||
>> unsplit :: (<span class="dt"
|
>> <span class="ot"
|
||||||
|
>unsplit </span
|
||||||
|
><span class="ot"
|
||||||
|
>::</span
|
||||||
|
> (<span class="dt"
|
||||||
>Arrow</span
|
>Arrow</span
|
||||||
> a) => (b -> c -> d) -> a (b, c) d<br
|
> a) <span class="ot"
|
||||||
|
>=></span
|
||||||
|
> (b <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> c <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> d) <span class="ot"
|
||||||
|
>-></span
|
||||||
|
> a (b, c) d<br
|
||||||
/>> unsplit <span class="fu"
|
/>> unsplit <span class="fu"
|
||||||
>=</span
|
>=</span
|
||||||
> arr <span class="fu"
|
> arr <span class="fu"
|
||||||
|
|
|
@ -12,17 +12,17 @@
|
||||||
|
|
||||||
\section{lhs test}
|
\section{lhs test}
|
||||||
|
|
||||||
\verb!unsplit! is an arrow that takes a pair of values and combines
|
\verb!unsplit! is an arrow that takes a pair of values and combines them to
|
||||||
them to return a single value:
|
return a single value:
|
||||||
|
|
||||||
\begin{verbatim}
|
\begin{verbatim}
|
||||||
unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
||||||
unsplit = arr . uncurry
|
unsplit = arr . uncurry
|
||||||
-- arr (\op (x,y) -> x `op` y)
|
-- arr (\op (x,y) -> x `op` y)
|
||||||
\end{verbatim}
|
\end{verbatim}
|
||||||
\verb!(***)! combines two arrows into a new arrow by running the
|
\verb!(***)! combines two arrows into a new arrow by running the two arrows on
|
||||||
two arrows on a pair of values (one arrow on the first item of the
|
a pair of values (one arrow on the first item of the pair and one arrow on the
|
||||||
pair and one arrow on the second item of the pair).
|
second item of the pair).
|
||||||
|
|
||||||
\begin{verbatim}
|
\begin{verbatim}
|
||||||
f *** g = first f >>> second g
|
f *** g = first f >>> second g
|
||||||
|
|
|
@ -14,17 +14,17 @@
|
||||||
|
|
||||||
\section{lhs test}
|
\section{lhs test}
|
||||||
|
|
||||||
\verb!unsplit! is an arrow that takes a pair of values and combines
|
\verb!unsplit! is an arrow that takes a pair of values and combines them to
|
||||||
them to return a single value:
|
return a single value:
|
||||||
|
|
||||||
\begin{code}
|
\begin{code}
|
||||||
unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
||||||
unsplit = arr . uncurry
|
unsplit = arr . uncurry
|
||||||
-- arr (\op (x,y) -> x `op` y)
|
-- arr (\op (x,y) -> x `op` y)
|
||||||
\end{code}
|
\end{code}
|
||||||
\verb!(***)! combines two arrows into a new arrow by running the
|
\verb!(***)! combines two arrows into a new arrow by running the two arrows on
|
||||||
two arrows on a pair of values (one arrow on the first item of the
|
a pair of values (one arrow on the first item of the pair and one arrow on the
|
||||||
pair and one arrow on the second item of the pair).
|
second item of the pair).
|
||||||
|
|
||||||
\begin{verbatim}
|
\begin{verbatim}
|
||||||
f *** g = first f >>> second g
|
f *** g = first f >>> second g
|
||||||
|
|
|
@ -1,19 +1,20 @@
|
||||||
lhs test
|
lhs test
|
||||||
========
|
========
|
||||||
|
|
||||||
`unsplit` is an arrow that takes a pair of values and combines them
|
`unsplit` is an arrow that takes a pair of values and combines them to return
|
||||||
to return a single value:
|
a single value:
|
||||||
|
|
||||||
> unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
> unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
||||||
> unsplit = arr . uncurry
|
> unsplit = arr . uncurry
|
||||||
> -- arr (\op (x,y) -> x `op` y)
|
> -- arr (\op (x,y) -> x `op` y)
|
||||||
|
|
||||||
`(***)` combines two arrows into a new arrow by running the two
|
`(***)` combines two arrows into a new arrow by running the two arrows on a
|
||||||
arrows on a pair of values (one arrow on the first item of the pair
|
pair of values (one arrow on the first item of the pair and one arrow on the
|
||||||
and one arrow on the second item of the pair).
|
second item of the pair).
|
||||||
|
|
||||||
f *** g = first f >>> second g
|
f *** g = first f >>> second g
|
||||||
|
|
||||||
Block quote:
|
Block quote:
|
||||||
|
|
||||||
> foo bar
|
> foo bar
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
lhs test
|
lhs test
|
||||||
========
|
========
|
||||||
|
|
||||||
``unsplit`` is an arrow that takes a pair of values and combines
|
``unsplit`` is an arrow that takes a pair of values and combines them to
|
||||||
them to return a single value:
|
return a single value:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
|
@ -10,9 +10,9 @@ them to return a single value:
|
||||||
unsplit = arr . uncurry
|
unsplit = arr . uncurry
|
||||||
-- arr (\op (x,y) -> x `op` y)
|
-- arr (\op (x,y) -> x `op` y)
|
||||||
|
|
||||||
``(***)`` combines two arrows into a new arrow by running the two
|
``(***)`` combines two arrows into a new arrow by running the two arrows on a
|
||||||
arrows on a pair of values (one arrow on the first item of the pair
|
pair of values (one arrow on the first item of the pair and one arrow on the
|
||||||
and one arrow on the second item of the pair).
|
second item of the pair).
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
|
@ -21,4 +21,3 @@ and one arrow on the second item of the pair).
|
||||||
Block quote:
|
Block quote:
|
||||||
|
|
||||||
foo bar
|
foo bar
|
||||||
|
|
||||||
|
|
|
@ -1,16 +1,16 @@
|
||||||
lhs test
|
lhs test
|
||||||
========
|
========
|
||||||
|
|
||||||
``unsplit`` is an arrow that takes a pair of values and combines
|
``unsplit`` is an arrow that takes a pair of values and combines them to
|
||||||
them to return a single value:
|
return a single value:
|
||||||
|
|
||||||
> unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
> unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
|
||||||
> unsplit = arr . uncurry
|
> unsplit = arr . uncurry
|
||||||
> -- arr (\op (x,y) -> x `op` y)
|
> -- arr (\op (x,y) -> x `op` y)
|
||||||
|
|
||||||
``(***)`` combines two arrows into a new arrow by running the two
|
``(***)`` combines two arrows into a new arrow by running the two arrows on a
|
||||||
arrows on a pair of values (one arrow on the first item of the pair
|
pair of values (one arrow on the first item of the pair and one arrow on the
|
||||||
and one arrow on the second item of the pair).
|
second item of the pair).
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
|
@ -19,4 +19,3 @@ and one arrow on the second item of the pair).
|
||||||
Block quote:
|
Block quote:
|
||||||
|
|
||||||
foo bar
|
foo bar
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue