@@ -23,6 +23,7 @@ module Streamly.Internal.Data.Producer.Type
2323 -- * Mapping
2424 , translate
2525 , lmap
26+ , lmap_
2627
2728 -- * Nesting
2829 , NestedLoop (..)
@@ -112,6 +113,13 @@ translate f g (Producer step inject extract) =
112113lmap :: (a -> a) -> Producer m a b -> Producer m a b
113114lmap f (Producer step inject extract) = Producer step (inject . f) extract
114115
116+-- | Map the producer input using the provided translation functions
117+--
118+-- /Pre-release/
119+{-# INLINE_NORMAL lmap_ #-}
120+lmap_ :: Functor m => (a -> c) -> (c -> a) -> Producer m c b -> Producer m a b
121+lmap_ f g (Producer step inject extract) = Producer step (inject . f) (fmap g . extract)
122+
115123------------------------------------------------------------------------------
116124-- Functor
117125------------------------------------------------------------------------------