Hi All,
I am a newbie to antlr. I am in the process of building a tree parser
using the AST rewrite rules that I've coded in the parser grammar file.
However I am running into RecognitionException when I use the tree
grammar to parse the AST generated using the parser grammar. I've used
the fol
Hi Gurus,
I'm a novice using ANTLR for a development project. I am at a stage
where I need to rewrite AST so that the transformed AST renders itself
more easy for me to walk and emit the translation that I need. In this
context I've a concept question.
In general, can I use the *same* tree
ng a version that does not have this dependency, so i can base my
> trees on BaseTree, rather than CommonTree.
>
> On 2011 Jun 11, at 00:53, srinivasan karthikeyan pitchai wrote:
>
>> Hi Gurus,
>> I'm a novice using ANTLR for a development project. I am at a stag
Hi Folks,
What does the ANTLR walker error message like the following mean?
no viable alt; token=[@-1,0:0='DOWN'
Would appreciate any general guidance/suggestions to zero in on the
errors of this nature.
Thanks,
Vasan
Input sql:
---
select (1) from table1
where 2 between 3 and 4;
;>> Mostly the error says that you started a subtree that your grammar
>>> does not match, probably an LPAREN or RPAREN rooted subtree from your
>>> report of cases where you do or do not get the error.
>>>
>>> --Loring
>>>
>>>
>>&
Thu, Jul 21, 2011 at 3:15 AM, Loring Craymer
>>> wrote:
>>>
>>>> "UP" and "DOWN" tokens (start/end of child list for tree) do not have
>>>> location information attached so no line/column error reporting.
>>>> Mostly the err
Vasan
On 7/21/2011 10:59 AM, srinivasan karthikeyan pitchai wrote:
> Hi Folks,
> I forgot to mention. The compoundExpression rule has options{backtrack
> = true;} set that is it reads like
>
> compoundExpression
> options {backtrack = true;}
> :
>^(scl
rules as the first element of a tree, its just not
> something that turns up in my tree grammars.
>
> Regards
> Gary
>
> On Thu, Jul 21, 2011 at 3:29 PM, srinivasan karthikeyan pitchai<
> srinivasan.karthikeyan.pitc...@oracle.com> wrote:
>
>> Hi Folks,
>> I forgo
Hi Folks,
I take on board the unanimous input that the tree grammar rule should
start with TOKEN.
However what keeps me puzzled is that, inspite of having all my rules
intact and just slightly rejigging my alternatives make the tree grammar
parse the input tree perfectly fine. I am able to par