1 grammar t053heteroTP15; 2 options { 3 language=JavaScript; 4 output=AST; 5 tokenVocab=t053heteroT15; 6 ASTLabelType=CommonTree; 7 } 8 tokens { ROOT; } 9 @header { 10 function V15(ttype) { 11 V15.superclass.constructor.call(this, new org.antlr.runtime.CommonToken(ttype)); 12 }; 13 org.antlr.lang.extend(V15, org.antlr.runtime.tree.CommonTree, { 14 toString: function() { 15 return t053heteroTP15Parser.tokenNames[this.getType()] + "<V>"; 16 } 17 }); 18 } 19 a : ID -> ROOT<V15> ID 20 ; 21 22