[antlr-interest] Impossible to reference more than one global scope?

Matthieu Riou matthieu at offthelip.org
Thu Jan 31 15:15:31 PST 2008


Hi,

I've having some problems with a rule that needs to reference two global
scopes:

scope BPELScope { OScope oscope; }
scope Parent { OActivity activity; }
...
process
scope BPELScope, Parent;
        :           ...

This leads to a "expecting SEMI, found ',' " error. Moreover the java code
generated is missing a stack push as I only have the following:

Parent_stack.push(new Parent_scope());

The BPELScope stack should also be pushed a new value but it's not,
resulting in an EmptyStackException at runtime. I also tried specifying the
two scopes as two different lines like this:

process
scope BPELScope;
scope Parent;
        :           ...

The error disappears but the call to push a new value in the stack is still
missing resulting in the same EmptyStackException. Am I missing the right
way to specify several global scope references or is it a bug?

Thanks,
Matthieu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080131/2bd065a8/attachment-0001.html 


More information about the antlr-interest mailing list