[Haskell-cafe] explicit big lambdas

Paul Brauner paul.brauner at loria.fr
Thu Mar 25 09:03:54 EDT 2010


Thanks to all!

Paul

On Fri, Mar 19, 2010 at 04:24:17PM +0100, Bas van Dijk wrote:
> On Fri, Mar 19, 2010 at 4:03 AM, Nicolas Frisby
> <nicolas.frisby at gmail.com> wrote:
> > Alternatively:
> >
> > let f :: <some type involving a>
> >    f = ...
> >
> >    f' :: a -> <some type involving a>
> >    f' _ = f
> > in f' (undefined :: Int) <normal f arguments>
> 
> Or use Edward Kmett's tagged library:
> 
> http://hackage.haskell.org/packages/archive/tagged/0.0/doc/html/Data-Tagged.html
> 
> so you don't have to use bottom values:
> 
> let f :: <some type involving a>
>     f = ...
> 
>     f' :: Tagged a <some type involving a>
>     f' = Tagged f
> 
> regards,
> 
> Bas
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe


More information about the Haskell-Cafe mailing list