Mirror: The magical sticky regex-based parser generator 馃
at v1.0.1 578 B view raw
1export class SharedIds { 2 constructor(t) { 3 this.t = t; 4 this.execId = t.identifier('_exec'); 5 this.patternId = t.identifier('_pattern'); 6 this.tagId = t.identifier('tag'); 7 } 8 9 get node() { 10 return this.t.identifier('node'); 11 } 12 13 get match() { 14 return this.t.identifier('match'); 15 } 16 17 get state() { 18 return this.t.identifier('state'); 19 } 20 21 get exec() { 22 return this.t.identifier(this.execId.name); 23 } 24 25 get pattern() { 26 return this.t.identifier(this.patternId.name); 27 } 28 29 get tag() { 30 return this.t.identifier(this.tagId.name); 31 } 32}