Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
CoreFn traversal helpers
Synopsis
- everywhereOnValues :: (Bind a -> Bind a) -> (Expr a -> Expr a) -> (Binder a -> Binder a) -> (Bind a -> Bind a, Expr a -> Expr a, Binder a -> Binder a)
- traverseCoreFn :: forall f a. Applicative f => (Bind a -> f (Bind a)) -> (Expr a -> f (Expr a)) -> (Binder a -> f (Binder a)) -> (CaseAlternative a -> f (CaseAlternative a)) -> (Bind a -> f (Bind a), Expr a -> f (Expr a), Binder a -> f (Binder a), CaseAlternative a -> f (CaseAlternative a))
Documentation
everywhereOnValues :: (Bind a -> Bind a) -> (Expr a -> Expr a) -> (Binder a -> Binder a) -> (Bind a -> Bind a, Expr a -> Expr a, Binder a -> Binder a) Source #
traverseCoreFn :: forall f a. Applicative f => (Bind a -> f (Bind a)) -> (Expr a -> f (Expr a)) -> (Binder a -> f (Binder a)) -> (CaseAlternative a -> f (CaseAlternative a)) -> (Bind a -> f (Bind a), Expr a -> f (Expr a), Binder a -> f (Binder a), CaseAlternative a -> f (CaseAlternative a)) Source #
Apply the provided functions to the top level of AST nodes.
This function is useful as a building block for recursive functions, but doesn't actually recurse itself.