PROPOSAL: Include record puns in Haskell 2011

Isaac Dupree ml at
Wed Feb 24 15:31:05 EST 2010

On 02/24/10 13:40, Martijn van Steenbergen wrote:
> Ian Lynagh wrote:
>> I have a feeling I'm in the minority, but I find record punning an ugly
>> feature.
>> Given
>> data T = C { f :: Int }
>> we implicitly get
>> f :: T -> Int
>> which punning shadows with
>> f :: Int
>> whereas I generally avoid shadowing completely.
> I agree with Ian.

I tend to agree.

I don't mind if a few files that use a ton of label-operations are 
marked with NamedFieldPuns and use that feature a lot.  But, funnily, if 
it were put in the standard then it would be enabled in un-marked source 
files, and then I personally wouldn't like it as much. (Any decision is 
acceptable to me though.)


More information about the Haskell-prime mailing list