xref: /aosp_15_r20/external/antlr/runtime/JavaScript/tests/functional/t053heteroTP15.g (revision 16467b971bd3e2009fad32dd79016f2c7e421deb)
1*16467b97STreehugger Robotgrammar t053heteroTP15;
2*16467b97STreehugger Robotoptions {
3*16467b97STreehugger Robot    language=JavaScript;
4*16467b97STreehugger Robot    output=AST;
5*16467b97STreehugger Robot    tokenVocab=t053heteroT15;
6*16467b97STreehugger Robot    ASTLabelType=CommonTree;
7*16467b97STreehugger Robot}
8*16467b97STreehugger Robottokens { ROOT; }
9*16467b97STreehugger Robot@header {
10*16467b97STreehugger Robotfunction V15(ttype) {
11*16467b97STreehugger Robot    V15.superclass.constructor.call(this, new org.antlr.runtime.CommonToken(ttype));
12*16467b97STreehugger Robot};
13*16467b97STreehugger Robotorg.antlr.lang.extend(V15, org.antlr.runtime.tree.CommonTree, {
14*16467b97STreehugger Robot    toString: function() {
15*16467b97STreehugger Robot        return t053heteroTP15Parser.tokenNames[this.getType()] + "<V>";
16*16467b97STreehugger Robot    }
17*16467b97STreehugger Robot});
18*16467b97STreehugger Robot}
19*16467b97STreehugger Robota : ID -> ROOT<V15> ID
20*16467b97STreehugger Robot  ;
21*16467b97STreehugger Robot
22