On Tue, Apr 8, 2008 at 4:46 AM, Paul Keir <[EMAIL PROTECTED]> wrote:
>  I have noticed something interesting though. If I simply omit the "a"
>  from "opLetter", the problem is gone. In fact, leaving "opStart",
>  "opLetter", and "reservedOpNames" all empty works fine too.

That makes sense.  opLetter is there to support "user-defined"
operators, as many languages allow two distinct classes of
identifiers - one which looks like variables and one which looks
like symbolic operators.

If you don't want to allow user-defined operators which
contain "a", so that ":a:", a reserved keyword, is the only valid
identifier which contains both "a" and another member of
opLetter, you should be OK leaving "a" off of the list of
opLetters.  Indeed, you shouldn't actually need to specify ":a:"
in reservedOpNames either, since "reservedOp" doesn't check that
list, and the "operator" parser will already reject ":a:" because
it contains a non-opLetter.  Though, for sanity you might leave
it there anyway.

At least, I think so.

--Chris
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to