[antlr-interest] OPEN, EOF ambiguity

Cameron Ross cross at kojeware.com
Fri Apr 9 19:52:07 PDT 2010


Yes, this is the conclusion I'm coming to.  Thanks much.
Cameron.

Kojeware Corporation

On Apr 9, 2010, at 10:11 PM, "William B. Clodius" <wclodius at los-alamos.net
 > wrote:

>
> On Apr 9, 2010, at 11:02 AM, Cliff Hudson wrote:
>
>> Well, it's not always true that grammar specs are, for instance,
>> LALR(1) or
>> LL(k).  In such cases, you have to rejigger the grammar to make it
>> work.
>> The important thing is (or should be) that the grammar you do
>> produce,
>> regardless of the technicalities, will parse what you intend and
>> nothing
>> more.
> <snip>
> However it is often useful to make the grammar you parse be
> different from the official grammar for the language. Often some
> constructs that the language language differentiates in the syntax
> may best (sometimes only) be distinguished during the semantic
> analysis. Error reporting can also be better if the lexical and
> syntactic properties of the accepted language is looser than the
> official language, though care must be taken to ensure that the
> semantic analysis detects all such errors and does not acidently
> give such errors meaning.
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address


More information about the antlr-interest mailing list