Hoogle Search
Within LTS Haskell 24.33 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
mapMOf_ :: Monad m => Getting (Sequenced r m) s a -> (a -> m r) -> s -> m ()diagrams-lib Diagrams.Prelude Map each target of a Fold on a structure to a monadic action, evaluate these actions from left to right, and ignore the results.
>>> mapMOf_ both putStrLn ("hello","world") hello worldmapM_ ≡ mapMOf_ folded
mapMOf_ :: Monad m => Getter s a -> (a -> m r) -> s -> m () mapMOf_ :: Monad m => Fold s a -> (a -> m r) -> s -> m () mapMOf_ :: Monad m => Lens' s a -> (a -> m r) -> s -> m () mapMOf_ :: Monad m => Iso' s a -> (a -> m r) -> s -> m () mapMOf_ :: Monad m => Traversal' s a -> (a -> m r) -> s -> m () mapMOf_ :: Monad m => Prism' s a -> (a -> m r) -> s -> m ()
mapOf :: ASetter s t a b -> (a -> b) -> s -> tdiagrams-lib Diagrams.Prelude mapped :: forall (f :: Type -> Type) a b . Functor f => Setter (f a) (f b) a bdiagrams-lib Diagrams.Prelude This Setter can be used to map over all of the values in a Functor.
fmap ≡ over mapped fmapDefault ≡ over traverse (<$) ≡ set mapped
>>> over mapped f [a,b,c] [f a,f b,f c]
>>> over mapped (+1) [1,2,3] [2,3,4]
>>> set mapped x [a,b,c] [x,x,x]
>>> [[a,b],[c]] & mapped.mapped +~ x [[a + x,b + x],[c + x]]
>>> over (mapped._2) length [("hello","world"),("leaders","!!!")] [("hello",5),("leaders",3)]mapped :: Functor f => Setter (f a) (f b) a b
If you want an IndexPreservingSetter use setting fmap.-
diagrams-lib Diagrams.Prelude mappingNamer :: (String -> [String]) -> FieldNamerdiagrams-lib Diagrams.Prelude Create a FieldNamer from a mapping function. If the function returns [], it creates no lens for the field.
mapSegmentVectors :: (v n -> v' n') -> Segment c v n -> Segment c v' n'diagrams-lib Diagrams.Segment Map over the vectors of each segment.
mapAccumL :: TextualMonoid t => (a -> Char -> (a, Char)) -> a -> t -> (a, t)monoid-subclasses Data.Monoid.Textual Equivalent to mapAccumL from Data.List when applied to a String, but preserves all non-character data.
mapAccumR :: TextualMonoid t => (a -> Char -> (a, Char)) -> a -> t -> (a, t)monoid-subclasses Data.Monoid.Textual Equivalent to mapAccumR from Data.List when applied to a String, but preserves all non-character data.
mapM :: (Factorial a, Semigroup b, Monoid b, Monad m) => (a -> m b) -> a -> m bmonoid-subclasses Data.Semigroup.Factorial A mapM equivalent.
mapM_ :: (Factorial a, Applicative m) => (a -> m b) -> a -> m ()monoid-subclasses Data.Semigroup.Factorial A mapM_ equivalent.