On Fri, 29 Apr 2011 03:27:48 +0200 Daniel Fischer <daniel.is.fischer@googlemail.com> wrote:
On Friday 29 April 2011 02:35:13, Graham Hopper wrote: Basically, a pattern is [...] Or
- a constructor application, (Con arg1 arg2), (x:xs), (a,b,c,d), ((:) x xs) [...] Also there are [...]
I've been wondering about this case. Since : is "just another function", then if things were consistent, I ought to be able to use other functions in constructor applications. But my attempts to do so always seem to result in syntax errors. So my question is - what are the rules for constructor applications? Is the list above complete? Are there just a few more? Is there some rule to determine which functions are ok in patterns and which aren't? Thanks, <mike -- Mike Meyer <mwm@mired.org> http://www.mired.org/consulting.html Independent Software developer/SCM consultant, email for more information. O< ascii ribbon campaign - stop html mail - www.asciiribbon.org