[m-dev.] Mercury char syntax

Michael Day mikeday at yeslogic.com
Sun Apr 6 19:53:25 AEST 2003


> One option that comes to mind is `x' with some rules to disallow
> or disambiguate odd things like ``x'`.  `+' would parse as a char and
> not as an infix operator, so parentheses would be unnecessary.

The other option would be to use 'x' for everything, changing the parsing
so that parentheses were not necessary for '-' and others. Consistent
across all chars and with other languages.

(Seriously, the ('-') thing has bitten me and others many times, and it
invariably leads to an annoyed reaction - "what kind of language allows an
operator *in quotes* like that???").

Michael

--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list