
On Tue, Jul 07, 2009 at 10:28:11AM -0400, Ravi Nanavati wrote:
2. Once deprecated, people will be encouraged to not depend on the traditional record syntax where the cost of avoiding it is small (I'm thinking of situations like the mtl-accessors / run functions where the traditional syntax is saving something like one function definition). 3. Champions of alternative record syntaxes will know what on Hackage they can use out-of-the-box and what things they'd want to consider re-writing as examples of how their approach is superior.
Well, that's the problem. I don't want to ever deprecate the named field mechanism as it is completely independent of a record system. You can think of the possibilites as follows. named positional declared LabeledFields DataDeclarations anonymous ???? Tuples So, a record syntax fills the hole of anonymous, named field types. However, we shouldn't do it at the expense of opening another hole with declared, named field types any more than we should dispose of standard data declations in favor of making everything newtypes of tuples. Also, this supports the idea of using parethensis rather than braces for a record mechanism. this would be consistent with tuples in that parens = anonymous. Also, if you just replace braces with parens in the scoped records paper, you get no conflicts with existing syntax. (including named fields) :) John -- John Meacham - ⑆repetae.net⑆john⑈ - http://notanumber.net/