#haskell - Sun 25 Mar 2007 between 00:36 and 00:42

NY Lost Funds



lambdabotSource not found. Maybe if you used more than just two fingers...
nmessenger(polymorphic on arbitrary Functors)
@src [] fmap
lambdabotfmap = map
jcreigh> fmap (*2) [1,2,3]
nmessenger@src Tree fmap
lambdabotSource not found. Sorry about this, I know it's a bit silly.
[2,4,6]
nmessenger@src Maybe fmap
lambdabotfmap _ Nothing = Nothing
fmap f (Just a) = Just (f a)
nmessengeretc.
dmeadhmm
i'll discuss more later
Saizan@src (a (->)) fmap
lambdabotSource not found. Where did you learn to type?
dmeadgotta go
be back in a few hours
sorearhttp://haskell.org/pipermail/libraries/2007-February/index.html
lambdabotTitle: The Libraries February 2007 Archive by thread
actiondmead is away: coffee
dmeadis away: coffee
sorearops
http://haskell.org/pipermail/libraries/2007-February/006909.html
lambdabotTitle: Where prelude alternatives/ classes and types to get values?
sorearread that, esp. second paragraph
s/^/nmessenger: /
actiondmwit rubs his eyes and looks around sleepily, then turns off his speakers
dmwitrubs his eyes and looks around sleepily, then turns off his speakers
sorear@src (->) fmap
lambdabotfmap = (.)
sorear@src Data.Tree fmap
lambdabotSource not found. It can only be attributed to human error.
sorear@src (,) fmap
lambdabotfmap f (x,y) = (x, f y)
sorear@src Either fmap
lambdabotfmap _ (Left x) = Left x
fmap f (Right y) = Right (f y)
sorear@src is not very friendly, you need a lot of experience to use it well :()
nmessenger{- Data.Tree -} fmap (Node x xs) = Node (f x) (map (fmap f) xs) -- I believe
oops s/fmap/fmap f/ :)
jcreighI feel like it's more confusing (to me) to have fmap vs. map, when they're both really the same thing.

Page: 4 11 18 25 32 39 46 53 60 67 74 81 88 95 102 109 

IrcArchive

NY Lost Funds