Re: Proposal: Num instance for tuples

wren ng thornton <[email protected]>
Newsgroups gmane.comp.lang.haskell.libraries,gmane.comp.lang.haskell.cvs.ghc
Message-ID <[email protected]>
On 10/19/12 7:29 AM, Simon Marlow wrote:
> On 18/10/2012 11:07, Henning Thielemann wrote:
>>
>> On Thu, 18 Oct 2012, Twan van Laarhoven wrote:
>>
>>> One piece of utility code that I find myself writing over and over
>>> again is the pointwise Num instance for tuples, i.e.
>>
>> For my taste, writing
>>
>>    2 :: (Int, Integer)
>>
>>    abs (x,y)
>>
>> should yield a compiler error and the compiler should not try to
>> interpret it in some way. For the cases where you need these instances I
>> suggest you use custom data types.
>
> Agreed, -1 from me.

Agreed, another -1.

-- 
Live well,
~wren
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.