1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
-----------------------------------------------------------------------------
-- |
-- Module : Control.Arrow.Transformer
-- Copyright : (c) Ross Paterson 2003
-- License : BSD-style (see the LICENSE file in the distribution)
--
-- Maintainer : ross@soi.city.ac.uk
-- Stability : experimental
-- Portability : portable
--
-- Arrow transformers, for making new arrow types out of old ones.
module Control.Arrow.Transformer (
ArrowTransformer(..)
) where
import Control.Arrow
-- | Construct a new arrow from an existing one.
class (Arrow a, Arrow (f a)) => ArrowTransformer f a where
-- | A transformation of arrows, preserving 'arr', '>>>' and 'first'.
--
-- Typical usage in arrow notation:
--
-- > proc p -> ...
-- > (|lift cmd|)
lift :: a b c -> f a b c
|