Proposal: Add a catamorphism on Trees
Edward Kmett
ekmett at gmail.com
Tue May 17 22:35:31 UTC 2016
No objection here.
+1
On Tue, May 17, 2016 at 5:03 PM, David Feuer <david.feuer at gmail.com> wrote:
> Daniel Wagner would like to add the following straightforward function
> to Data.Tree. I think this is a grand idea.
>
> foldTree :: (a -> [b] -> b) -> Tree a -> b
> foldTree f = go
> where
> go (Node x ts) = f x (map go ts)
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20160517/251e7db6/attachment.html>
More information about the Libraries
mailing list