History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: ANTLR-96
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Terence Parr
Reporter: Terence Parr
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
ANTLR v3

literals not always defined in implicitly-generated lexer

Created: 15/Mar/07 11:23 AM   Updated: 25/Dec/07 04:40 PM
Component/s: ANTLR Core
Affects Version/s: 3.0b6
Fix Version/s: 3.0b7


 Description  « Hide
grammar U;

sentence
            : 'abc' 'x'
            | Item
            ;
           
Item: 'x' '0' '9' ;

yields lexer:

lexer grammar U;

T5 : 'abc' ;
            
// $ANTLR src "U.g" 8
Item: 'x' '0' '9' ;


 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
Terence Parr - 26/Mar/07 06:38 PM
I was not matching trees properly for token name aliases.

E : 'a' 'x' ;

made E an alias for 'a'. :(