[antlr-interest] Error in produced lexer
Terence Parr
parrt at cs.usfca.edu
Tue May 15 09:15:50 PDT 2007
On May 15, 2007, at 8:34 AM, Alex Shneyderman wrote:
> I am on 3.0b7 of ANTLR and was trying to learn about syntactic
> predicates today. So, I have the lexer described as so:
>
> int alt=;
This bug is fixed in the latest daily build. Grab from /download/
build :)
Ter
> switch (alt) {
> case 1 :
> // Disambiguation.g:17:5: DIGIT
> {
> mDIGIT(); if (failed) return ;
>
> }
> break;
>
> default :
> if ( cnt >= 1 ) break loop;
> if (backtracking>0) {failed=true; return ;}
> EarlyExitException eee =
> new EarlyExitException(, input);
> throw eee;
> }
> cnt++;
> } while (true);
>
> match('.'); if (failed) return ;
> mDIGIT(); if (failed) return ;
>
> }
> }
> // $ANTLR end synpred1
>
> which is not a valid java.
> Anyone knows how to fix this?
>
> --
> Thanks,
> Alex.
More information about the antlr-interest
mailing list