[Haskell-cafe] Maybe type filtered

Jon Fairbairn jon.fairbairn at cl.cam.ac.uk
Thu Jan 3 10:33:02 UTC 2019

Ivan Lazar Miljenovic <ivan.miljenovic at gmail.com> writes:

> That's because you still have "Just a" values. Try mapMaybe from Data.Maybe
> instead.

Sounds like a job for catMaybes from Data.Maybe

catMaybes [Nothing, Just "foo"] ==> ["foo"]
Jón Fairbairn                                 Jon.Fairbairn at cl.cam.ac.uk

More information about the Haskell-Cafe mailing list