[antlr-interest] Repost: ANTLRworks: Why do these rules behave differently in the embedded interpreter?

Kyle Ferrio kferrio at gmail.com
Fri Jan 1 13:58:39 PST 2010


Thanks, folks.

David-Sarah makes a good point, which I would make perhaps just a bit
differently, and this is I see the interpreter as a kind of learning
tool, a crutch if you will.  If it goes wonky in a way that makes it
obvious to a knave that it's at fault, fine.  But if it goes wonky in
a way which causes the student to wonder, "Is this me, or is this the
tool?" then learning is impeded at a critical juncture, even if the
ultimate resolution (assuming a persistent student) does produce
deeper insight.

Note: I manage a commercial software development group serving highly
specialized engineering customers.  More than one customer has told me
that he or she would rather have "a tool that fails in an obvious way"
more often than "a tool which fails in an ambiguous way less often."
{Quotes added to assist parsing.  :) }  It's not about being right or
wrong.  It's about knowing when you can trust your tools, and when you
shouldn't.

Kyle



On Fri, Jan 1, 2010 at 1:31 PM, Terence Parr <parrt at cs.usfca.edu> wrote:
>
> On Jan 1, 2010, at 11:45 AM, David-Sarah Hopwood wrote:
>
>> Jim Idle wrote:
>>> The interpreter is just a quick testing device and is easily fooled by grammar rules, use the debugger and not the interpreter and all will be fine.
>>
>> Yes, but what Kyle pointed out seems like an obvious bug in the
>> interpreter in a case that it is supposed to be able to handle.
>>
>> Either bugs like this should be fixed, or there is no point in having
>> the interpreter and all and it should be removed, with its functionality
>> being replaced by the debugger.
>
> yup. it's on my to-do list.
> T
>
> 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