Hoogle Search
Within LTS Haskell 24.40 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
ifor_ :: (FoldableWithIndex i t, Applicative f) => t a -> (i -> a -> f b) -> f ()lens Control.Lens.Combinators Traverse elements with access to the index i, discarding the results (with the arguments flipped).
ifor_ ≡ flip itraverse_
When you don't need access to the index then for_ is more flexible in what it accepts.for_ a ≡ ifor_ a . const
lensRulesFor :: [(String, String)] -> LensRuleslens Control.Lens.Combinators Construct a LensRules value for generating top-level definitions using the given map from field names to definition names.
makeClassyFor :: String -> String -> [(String, String)] -> Name -> DecsQlens Control.Lens.Combinators Derive lenses and traversals, using a named wrapper class, and specifying explicit pairings of (fieldName, traversalName). Example usage:
makeClassyFor "HasFoo" "foo" [("_foo", "fooLens"), ("bar", "lbar")] ''Foo
makeLensesFor :: [(String, String)] -> Name -> DecsQlens Control.Lens.Combinators Derive lenses and traversals, specifying explicit pairings of (fieldName, lensName). If you map multiple names to the same label, and it is present in the same constructor then this will generate a Traversal. e.g.
makeLensesFor [("_foo", "fooLens"), ("baz", "lbaz")] ''Foo makeLensesFor [("_barX", "bar"), ("_barY", "bar")] ''Bar
transform :: Plated a => (a -> a) -> a -> alens Control.Lens.Combinators Transform every element in the tree, in a bottom-up manner. For example, replacing negative literals with literals:
negLits = transform $ \x -> case x of Neg (Lit i) -> Lit (negate i) _ -> x
transformM :: (Monad m, Plated a) => (a -> m a) -> a -> m alens Control.Lens.Combinators Transform every element in the tree, in a bottom-up manner, monadically.
transformMOf :: Monad m => LensLike (WrappedMonad m) a b a b -> (b -> m b) -> a -> m blens Control.Lens.Combinators Transform every element in a tree using a user supplied Traversal in a bottom-up manner with a monadic effect.
transformMOf :: Monad m => Traversal' a a -> (a -> m a) -> a -> m a
transformMOn :: (Monad m, Plated a) => LensLike (WrappedMonad m) s t a a -> (a -> m a) -> s -> m tlens Control.Lens.Combinators Transform every element in the tree in a region indicated by a supplied Traversal, in a bottom-up manner, monadically.
transformMOn :: (Monad m, Plated a) => Traversal' s a -> (a -> m a) -> s -> m s
-
lens Control.Lens.Combinators Transform every element in a tree that lies in a region indicated by a supplied Traversal, walking with a user supplied Traversal in a bottom-up manner with a monadic effect.
transformMOnOf :: Monad m => Traversal' s a -> Traversal' a a -> (a -> m a) -> s -> m s
transformOf :: ASetter a b a b -> (b -> b) -> a -> blens Control.Lens.Combinators Transform every element by recursively applying a given Setter in a bottom-up manner.
transformOf :: Traversal' a a -> (a -> a) -> a -> a transformOf :: Setter' a a -> (a -> a) -> a -> a