1 2 grammar t058rewriteAST3; 3 options {language=JavaScript;output=AST;} 4 a : ID -> ID["x"]; 5 ID : 'a'..'z'+ ; 6 INT : '0'..'9'+; 7 WS : (' '|'\n') {$channel=HIDDEN;} ;