Adding an ignore function to Control.Monad

Edward Kmett ekmett at gmail.com
Thu Jul 2 04:00:15 EDT 2009


I agree with Neil on all those points. F.M.E.void has too many things to fix
to bring it inline with ignore in one go and a worse name.

+1 on adding ignore though.

-Edward Kmett

On Thu, Jul 2, 2009 at 2:26 AM, Neil Mitchell <ndmitchell at gmail.com> wrote:

> void is the wrong name, wrong type, wrong purpose and wrong module. We
> could fix all those things, but I think we should just add ignore as
> previously agreed (+1 for that)
>
> Thanks, Neil
>
> On Thu, Jul 2, 2009 at 4:11 AM, Isaac
> Dupree<ml at isaac.cedarswampstudios.org> wrote:
> > Gwern Branwen wrote:
> >>
> >> Since then, Don Stewart has pointed out
> >> http://hackage.haskell.org/trac/ghc/ticket/3292 that there is a very
> >> similar function specified in the FFI standard
> >>
> http://www.cse.unsw.edu.au/~chak/haskell/ffi/ffi/ffise5.html#x8-350005.10
> >> - 'void     :: IO a -> IO ()'.
> >
> > Are we willing to change (generalize) the type of
> > Foreign.Marshal.Error.void?  If so, we could export (void :: Functor m =>
> m
> > a -> m ()) from both Control.Monad and F.M.E (if we wanted to).  If we're
> > not willing, then I think it would be a bit more convenient to name them
> > different things (so that if you import both modules you don't get a
> > name-conflict for using 'void').
> >
> > I vote to just name it Control.Monad.ignore .  Many people independently
> > invented the name "ignore" in their own projects.  Also I suspect the
> name
> > "void" in FFI has some etymology in C's equivalent, casting expressions
> to
> > void (eg: (void)printf(something); ) which I doubt most haskell coders
> care
> > about most of the time?
> >
> > -Isaac
> > _______________________________________________
> > Libraries mailing list
> > Libraries at haskell.org
> > http://www.haskell.org/mailman/listinfo/libraries
> >
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://www.haskell.org/mailman/listinfo/libraries
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/libraries/attachments/20090702/e49a3b05/attachment.html


More information about the Libraries mailing list