
On 22/11/10 11:41, Ian Lynagh wrote:
Hi Iavor,
Thanks for your comments.
On Sun, Nov 21, 2010 at 06:25:38PM -0800, Iavor Diatchki wrote:
* Why is "forall" promoted to a keyword, rather then just being special in types as is in all implementations? I like the current status quo where "forall" can still be used in value expressions.
You can't use "case" as a type variable, so I don't see why you should be able to use "forall" as an expression variable.
I imagine that the reason implementations currently allow it is to minimise the chance of an extension breaking existing programs, but I believe that when making new versions of the standard we should, where feasible, write them in the way that they would have been written if the previous versions had never existed.
We tend not to make new global keywords when we can avoid doing so. 'hiding', 'qualified', 'as', 'safe', 'unsafe', 'dynamic' etc. are all examples of identifiers interpreted as keywords only in certain contexts. I don't think it's feasible to allow 'case' as a type variable, but it's certainly feasible to allow 'forall' as a term variable. On the other hand, it makes life difficult for syntax highlighters. Cheers, Simon