[Haskell-cafe] foild function for expressions

Ryan Ingram ryani.spam at gmail.com
Mon Dec 3 18:36:10 EST 2007

On 12/3/07, Kalman Noel <kalman.noel at bluebottle.com> wrote:
> You're confusing sum and product types. That is, you're using a product
> type,
> but you probably need a sum type, like this:

I'm not so sure; it looks like they already have that type (Exp) and wants
to use AlgExp to hold the "folding" functions used.

Carlo, I think you're on the right track. Think of it this way: you have
some Exps and you want to get some things of type "a" to pass to the
functions in alg.  How could you get those things with what you have so far?

  -- ryan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20071203/f55c9353/attachment.htm

More information about the Haskell-Cafe mailing list