[Haskell-beginners] Foldable for (,)

Tony Morris tmorris at tmorris.net
Mon Apr 24 10:30:54 UTC 2017


I only know that the length of any forall a. ((,) a) is going to be one.
When it is polymorphic, I don't know that it is ((,) a) although it might
be at the call site, and so I don't know the length.

On Mon, Apr 24, 2017 at 4:52 PM, Jonathon Delgado <voldermort at hotmail.com>
wrote:

> Tony Morris - please could you give a (practical) example of code where
> the a tuple could realistically be passed to length, but you don't know
> what the answer will be at compile time?
>
> Michael Orlitzky - everything in .NET has to descend from Object because
> of it's OO design. Why does tuple have to implement Foldable if it doesn't
> provide any useful functions?
>
> Thank you very much everyone in this thread for helping me understand!
> _______________________________________________
> Beginners mailing list
> Beginners at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/beginners/attachments/20170424/103c927e/attachment-0001.html>


More information about the Beginners mailing list