import{a as i,i as l,j as m}from"./chunk-V335WFYB.js";var c=-1;function y(u,x,p,a){let r=l(u,a),t=new m(p);r.removeErrorListeners(),r.addErrorListener(t);let n=[],o=!1;do{let e=r.nextToken();if(e===null||e.type===c)o=!0;else{let s=x[e.type];s&&n.push({ruleName:s,startIndex:e.start,column:e.column,line:e.line,type:e.type,text:e.text})}}while(!o);return{tokens:n,errors:t.errors}}i(y,"tokenize");export{y as a};
