Control.Monad proposal: Add whenJust
haskell at benmachine.co.uk
Sun May 12 11:11:01 CEST 2013
On Sun, May 12, 2013 at 02:58:29AM +0200, Henning Thielemann wrote:
>On Sat, 11 May 2013, Simon Hengel wrote:
>>On Sat, May 11, 2013 at 06:15:53PM +0100, Ben Millwood wrote:
>>>Maybe what we really need to do is work out why Data.Foldable is so
>>>maligned, and sort out the import conflicts so it's easier to use.
>>Yes, sorting out the import conflicts would be awesome.
>There are no import conflicts if you import properly ...
That has its own problems – if every substantial patch involves touching
the import list, your patches don't merge. If instead of explicit import
lists you use qualification, then everyone names the module themselves
(no-one wants to write Data.Foldable) and possibly names it different
things (my habit is initial letters, until I need to import Data.Text
You can mostly minimise harm by only hiding specific things, but that's
still more effort than I feel like I should have to go to. I think if we
decide that the Foldable approach is useful enough to go in base, we
should not make it a second-class citizen.
More information about the Libraries