| Safe Haskell | None |
|---|
Control.Tweak.Internal
- data Maker a = Maker {}
- make :: Tweakable a -> Maker a
- apply :: IO (Tweakable (a -> b)) -> IO (Tweakable a) -> IO (Tweakable b)
- class Funktor g f where
- fcrap :: (a -> b) -> f a -> g b
- (.$.) :: Funktor g f => (a -> b) -> f a -> g b
- (.*.) :: Comply g h => g (a -> b) -> h a -> g b
- class Comply g h where
- connect :: g (a -> b) -> h a -> g b
Documentation
Maker is the Applicative used to create Tweakable expressions
Use the Applicative interface or the Applicative helpers
.$. and .*.
(.$.) :: Funktor g f => (a -> b) -> f a -> g bSource
This is slight variation on <$>. Use .$. and .*. avoid explicit
calls to make and Pure.
Unlike Functor the input and output * -> * type can change. There is no reasoning or laws behind it, it is just sugar.
The Funktor type class is closed and private. There are only instances
for Maker, Tweakable, and Var.
(.*.) :: Comply g h => g (a -> b) -> h a -> g bSource
This is slight variation on <*>. Use .$. and .*. avoid explicit
calls to make and Pure.
Unlike Apply, with Comply the input and output * -> * type can change. Like Funktor, there is no reasoning or laws behind it, it is just sugar.
The Comply type class is closed and private. There are only instances
for Maker, Tweakable, and Var.