1 Aug 2010 15:52
#4189: Add (<.>) operator (generalizing (.) to Functor)
Maciej Marcin Piechotka <uzytkownik2 <at> gmail.com>
2010-08-01 13:52:19 GMT
2010-08-01 13:52:19 GMT
The proposal is to add (<.>) function to Data.Functor/Control.Applicative: (<.>) :: (b -> c) -> (a -> f b) -> a -> f c f <.> g = fmap f . g -- (<.>) = (.) . fmap In intend it is related to <$> in the same way as (.) is related to $: (a . b . c) d = a $ b $ c $ d (a <.> b <.> c) d = a <$> b <$> c <$> d a is not specialized to f a to allow such chaining: const 1 <.> print <=< (read :: String -> Int) <.> readFile :: (Num t) => FilePath -> IO t Discussion deadline: 31th August 2010
_______________________________________________ Libraries mailing list Libraries <at> haskell.org http://www.haskell.org/mailman/listinfo/libraries
RSS Feed