Re: Eq instance for (a,b,c,d,e) and upwards



About this list Date view Thread view Subject view Author view

Marcin 'Qrczak' Kowalczyk (qrczak@knm.org.pl)
22 Apr 2001 20:32:33 GMT


Sun, 22 Apr 2001 20:34:30 +0200, Martin Norbäck <d95mback@dtek.chalmers.se> pisze: > > There is no upper bound on the size of a tuple. However, some > > Haskell implementations may restrict the size of tuples and > > limit the instances associated with larger tuples. > The sentence "All tuples are instances of Eq, Ord, Bounded, Read, and Show." > seems to require that all tuples that are allowed (12 with nhc98) should > also be instances of Eq, Ord, Bounded, Read and Show. But there is a disclaimer about instances for larger tuples too. I wish it wasn't there, so it would be unambiguously a but in ghc, hugs and nhc98. > Although I still think you should use a labelled record or at least > an own type for the kinds of values. My case was generated automatically and only one tuple out of many happened to be that big. Fortunately 'deriving Eq' was not really needed. -- __("< Marcin Kowalczyk * qrczak@knm.org.pl http://qrczak.ids.net.pl/ \__/ ^^ SYGNATURA ZASTÊPCZA QRCZAK


About this list Date view Thread view Subject view Author view