Skip to content

Add strict fmap

Add a strict version of fmap to the standard libraries.

infixl 4 <$!>
  
(<$!>) :: Monad m => (a -> b) -> m a -> m b
f <$!> m = do x <- m
              return $! f x
{-# INLINE (<$!>) #-}

Libraries discussions:

Take 1: http://www.haskell.org/pipermail/libraries/2013-November/021728.html Take 3: http://www.haskell.org/pipermail/libraries/2014-April/022864.html

Trac metadata
Trac field Value
Version 7.8.2
Type FeatureRequest
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component None
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information