mermaid12.3.05.3 MB
Shown as plain text from the published tarball, after apm checked it against the version's checksum. Nothing in it runs on this page.
The problem is in the <${r.name}> Token Type
For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error("non exhaustive match")}function dlt(r){return r.map(a=>typeof a=="string"?a.charCodeAt(0):a)}function y3e(r,t,a){r[t]===void 0?r[t]=[a]:r[t].push(a)}function u8(r){return r<Jie?r:b3e[r]}function b9r(){if(b3e.length===0){b3e=new Array(65536);for(let r=0;r<65536;r++)b3e[r]=r>255?255+~~(r/255):r}}function lW(r,t){let a=r.tokenTypeIdx;return a===t.tokenTypeIdx?!0:t.isParent===!0&&t.categoryMatchesMap[a]===!0}function fae(r,t){return r.tokenTypeIdx===t.tokenTypeIdx}function cW(r){let t=w9r(r);x9r(t),k9r(t),T9r(t),t.forEach(a=>{a.isParent=a.categoryMatches.length>0})}function w9r(r){let t=[...r],a=r,s=!0;for(;s;){a=a.map(h=>h.CATEGORIES).flat().filter(Boolean);let l=a.filter(h=>!t.includes(h));t=t.concat(l),l.length===0?s=!1:a=l}return t}function x9r(r){r.forEach(t=>{glt(t)||(v9r[vLr]=t,t.tokenTypeIdx=vLr++),gst(t)&&!Array.isArray(t.CATEGORIES)&&(t.CATEGORIES=[t.CATEGORIES]),gst(t)||(t.CATEGORIES=[]),C9r(t)||(t.categoryMatches=[]),E9r(t)||(t.categoryMatchesMap={})})}function T9r(r){r.forEach(t=>{t.categoryMatches=[],Object.keys(t.categoryMatchesMap).forEach(a=>{t.categoryMatches.push(v9r[a].tokenTypeIdx)})})}function k9r(r){r.forEach(t=>{plt([],t)})}function plt(r,t){r.forEach(a=>{t.categoryMatchesMap[a.tokenTypeIdx]=!0}),t.CATEGORIES.forEach(a=>{let s=r.concat(t);s.includes(a)||plt(s,a)})}function glt(r){return Object.hasOwn(r??{},"tokenTypeIdx")}function gst(r){return Object.hasOwn(r??{},"CATEGORIES")}function C9r(r){return Object.hasOwn(r??{},"categoryMatches")}function E9r(r){return Object.hasOwn(r??{},"categoryMatchesMap")}function S9r(r){return Object.hasOwn(r??{},"tokenTypeIdx")}function eB(r){return mlt(r)?r.LABEL:r.name}function mlt(r){return typeof r.LABEL=="string"&&r.LABEL!==""}function ylt(r){return A9r(r)}function A9r(r){let t=r.pattern,a={};if(a.name=r.name,t!==void 0&&(a.PATTERN=t),Object.hasOwn(r,hri))throw`The parent property is no longer supported.
See: https://github.com/chevrotain/chevrotain/issues/564#issuecomment-349062346 for details.`;return Object.hasOwn(r,wLr)&&(a.CATEGORIES=r[wLr]),cW([a]),Object.hasOwn(r,xLr)&&(a.LABEL=r[xLr]),Object.hasOwn(r,TLr)&&(a.GROUP=r[TLr]),Object.hasOwn(r,CLr)&&(a.POP_MODE=r[CLr]),Object.hasOwn(r,kLr)&&(a.PUSH_MODE=r[kLr]),Object.hasOwn(r,ELr)&&(a.LONGER_ALT=r[ELr]),Object.hasOwn(r,SLr)&&(a.LINE_BREAKS=r[SLr]),Object.hasOwn(r,ALr)&&(a.START_CHARS_HINT=r[ALr]),a}function h4e(r,t,a,s,l,h,f,d){return{image:t,startOffset:a,endOffset:s,startLine:l,endLine:h,startColumn:f,endColumn:d,tokenTypeIdx:r.tokenTypeIdx,tokenType:r}}function f4e(r,t){return lW(r,t)}function R9r(r,t){let a=new dri(r,t);return a.resolveRefs(),a.errors}function H3e(r,t,a=[]){a=[...a];let s=[],l=0;function h(d){return d.concat(r.slice(l+1))}i(h,"remainingPathWith"),J(h,"remainingPathWith");function f(d){let m=H3e(h(d),t,a);return s.concat(m)}for(i(f,"getAlternativesForProd"),J(f,"getAlternativesForProd");a.length<t&&l<r.length;){let d=r[l];if(d instanceof x2)return f(d.definition);if(d instanceof Bb)return f(d.definition);if(d instanceof b1)s=f(d.definition);else if(d instanceof ux){let m=d.definition.concat([new kp({definition:d.definition})]);return f(m)}else if(d instanceof hx){let m=[new x2({definition:d.definition}),new kp({definition:[new Af({terminalType:d.separator})].concat(d.definition)})];return f(m)}else if(d instanceof T2){let m=d.definition.concat([new kp({definition:[new Af({terminalType:d.separator})].concat(d.definition)})]);s=f(m)}else if(d instanceof kp){let m=d.definition.concat([new kp({definition:d.definition})]);s=f(m)}else{if(d instanceof k2)return d.definition.forEach(m=>{m.definition.length!==0&&(s=f(m.definition))}),s;if(d instanceof Af)a.push(d.terminalType);else throw Error("non exhaustive match")}l++}return s.push({partialPath:a,suffixDef:r.slice(l)}),s}function L9r(r,t,a,s){let l="EXIT_NONE_TERMINAL",h=[l],f="EXIT_ALTERNATIVE",d=!1,m=t.length,b=m-s-1,v=[],T=[];for(T.push({idx:-1,def:r,ruleStack:[],occurrenceStack:[]});T.length!==0;){let C=T.pop();if(C===f){d&&T.at(-1).idx<=b&&T.pop();continue}let E=C.def,S=C.idx,R=C.ruleStack,L=C.occurrenceStack;if(E.length===0)continue;let _=E[0];if(_===l){let I={idx:S,def:E.slice(1),ruleStack:R.slice(0,-1),occurrenceStack:L.slice(0,-1)};T.push(I)}else if(_ instanceof Af)if(S<m-1){let I=S+1,N=t[I];if(a(N,_.terminalType)){let B={idx:I,def:E.slice(1),ruleStack:R,occurrenceStack:L};T.push(B)}}else if(S===m-1)v.push({nextTokenType:_.terminalType,nextTokenOccurrence:_.idx,ruleStack:R,occurrenceStack:L}),d=!0;else throw Error("non exhaustive match");else if(_ instanceof Bb){let I=[...R];I.push(_.nonTerminalName);let N=[...L];N.push(_.idx);let B={idx:S,def:_.definition.concat(h,E.slice(1)),ruleStack:I,occurrenceStack:N};T.push(B)}else if(_ instanceof b1){let I={idx:S,def:E.slice(1),ruleStack:R,occurrenceStack:L};T.push(I),T.push(f);let N={idx:S,def:_.definition.concat(E.slice(1)),ruleStack:R,occurrenceStack:L};T.push(N)}else if(_ instanceof ux){let I=new kp({definition:_.definition,idx:_.idx}),N=_.definition.concat([I],E.slice(1)),B={idx:S,def:N,ruleStack:R,occurrenceStack:L};T.push(B)}else if(_ instanceof hx){let I=new Af({terminalType:_.separator}),N=new kp({definition:[I].concat(_.definition),idx:_.idx}),B=_.definition.concat([N],E.slice(1)),O={idx:S,def:B,ruleStack:R,occurrenceStack:L};T.push(O)}else if(_ instanceof T2){let I={idx:S,def:E.slice(1),ruleStack:R,occurrenceStack:L};T.push(I),T.push(f);let N=new Af({terminalType:_.separator}),B=new kp({definition:[N].concat(_.definition),idx:_.idx}),O=_.definition.concat([B],E.slice(1)),P={idx:S,def:O,ruleStack:R,occurrenceStack:L};T.push(P)}else if(_ instanceof kp){let I={idx:S,def:E.slice(1),ruleStack:R,occurrenceStack:L};T.push(I),T.push(f);let N=new kp({definition:_.definition,idx:_.idx}),B=_.definition.concat([N],E.slice(1)),O={idx:S,def:B,ruleStack:R,occurrenceStack:L};T.push(O)}else if(_ instanceof k2)for(let I=_.definition.length-1;I>=0;I--){let N=_.definition[I],B={idx:S,def:N.definition.concat(E.slice(1)),ruleStack:R,occurrenceStack:L};T.push(B),T.… line truncated, 14.5 kB in all
${h.join(`
`).replace(/\n/g,`
`)}`)}},"validateVisitor")};return a.prototype=s,a.prototype.constructor=a,a._RULE_NAMES=t,a}function pIr(r,t,a){let s=J(function(){},"derivedConstructor");Clt(s,r+"BaseSemanticsWithDefaults");let l=Object.create(a.prototype);return t.forEach(h=>{l[h]=fIr}),s.prototype=l,s.prototype.constructor=s,s}function gIr(r,t){return mIr(r,t)}function mIr(r,t){return t.filter(l=>typeof r[l]!="function").map(l=>({msg:`Missing visitor method: <${l}> on ${r.constructor.name} CST Visitor.`,type:Cst.MISSING_METHOD,methodName:l})).filter(Boolean)}function $V(r,t,a,s=!1){pae(a);let l=this.recordingProdStack.at(-1),h=typeof t=="function"?t:t.DEF,f=new r({definition:[],idx:a});return s&&(f.separator=t.SEP),Object.hasOwn(t,"MAX_LOOKAHEAD")&&(f.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(f),h.call(this),l.definition.push(f),this.recordingProdStack.pop(),m4e}function vIr(r,t){pae(t);let a=this.recordingProdStack.at(-1),s=Array.isArray(r)===!1,l=s===!1?r:r.DEF,h=new k2({definition:[],idx:t,ignoreAmbiguities:s&&r.IGNORE_AMBIGUITIES===!0});Object.hasOwn(r,"MAX_LOOKAHEAD")&&(h.maxLookahead=r.MAX_LOOKAHEAD);let f=l.some(d=>typeof d.GATE=="function");return h.hasPredicates=f,a.definition.push(h),l.forEach(d=>{let m=new x2({definition:[]});h.definition.push(m),Object.hasOwn(d,"IGNORE_AMBIGUITIES")?m.ignoreAmbiguities=d.IGNORE_AMBIGUITIES:Object.hasOwn(d,"GATE")&&(m.ignoreAmbiguities=!0),this.recordingProdStack.push(m),d.ALT.call(this),this.recordingProdStack.pop()}),m4e}function Est(r){return r===0?"":`${r}`}function pae(r){if(r<0||r>DLr){let t=new Error(`Invalid DSL Method idx value: <${r}>
Idx value must be a none negative value smaller than ${DLr+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}function wIr(r,t){t.forEach(a=>{let s=a.prototype;Object.getOwnPropertyNames(s).forEach(l=>{if(l==="constructor")return;let h=Object.getOwnPropertyDescriptor(s,l);h&&(h.get||h.set)?Object.defineProperty(r.prototype,l,h):r.prototype[l]=a.prototype[l]})})}function Sst(r=void 0){return function(){return r}}function TIr(r,t){for(var a=-1,s=r==null?0:r.length,l=Array(s);++a<s;)l[a]=t(r[a],a,r);return l}function CIr(){this.__data__=[],this.size=0}function EIr(r,t){return r===t||r!==r&&t!==t}function AIr(r,t){for(var a=r.length;a--;)if(SIr(r[a][0],t))return a;return-1}function RIr(r){var t=this.__data__,a=y4e(t,r);if(a<0)return!1;var s=t.length-1;return a==s?t.pop():Gri.call(t,a,1),--this.size,!0}function LIr(r){var t=this.__data__,a=y4e(t,r);return a<0?void 0:t[a][1]}function _Ir(r){return y4e(this.__data__,r)>-1}function DIr(r,t){var a=this.__data__,s=y4e(a,r);return s<0?(++this.size,a.push([r,t])):a[s][1]=t,this}function aB(r){var t=-1,a=r==null?0:r.length;for(this.clear();++t<a;){var s=r[t];this.set(s[0],s[1])}}function IIr(){this.__data__=new b4e,this.size=0}function MIr(r){var t=this.__data__,a=t.delete(r);return this.size=t.size,a}function NIr(r){return this.__data__.get(r)}function OIr(r){return this.__data__.has(r)}function FIr(r){var t=Zri.call(r,_ie),a=r[_ie];try{r[_ie]=void 0;var s=!0}catch{}var l=eni.call(r);return s&&(t?r[_ie]=a:delete r[_ie]),l}function $Ir(r){return nni.call(r)}function GIr(r){return r==null?r===void 0?sni:ani:ILr&&ILr in Object(r)?tni(r):ini(r)}function jIr(r){var t=typeof r;return r!=null&&(t=="object"||t=="function")}function zIr(r){if(!Slt(r))return!1;var t=hW(r);return t==lni||t==cni||t==oni||t==uni}function VIr(r){return!!MLr&&MLr in r}function WIr(r){if(r!=null){try{return pni.call(r)}catch{}try{return r+""}catch{}}return""}function HIr(r){if(!Slt(r)||fni(r))return!1;var t=UIr(r)?xni:mni;return t.test(sB(r))}function qIr(r,t){return r?.[t]}function YIr(r,t){var a=kni(r,t);return Tni(a)?a:void 0}function XIr(){this.__data__=mae?mae(null):{},this.size=0}function KIr(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}function JIr(r){var t=this.__data__;if(mae){var a=t[r];return a===Rni?void 0:a}return _ni.call(t,r)?t[r]:void 0}function QIr(r){var t=this.__data__;return mae?t[r]!==void 0:Mni.call(t,r)}function ZIr(r,t){var a=this.__data__;return this.size+=this.has(r)?0:1,a[r]=mae&&t===void 0?Oni:t,this}function oB(r){var t=-1,a=r==null?0:r.length;for(this.clear();++t<a;){var s=r[t];this.set(s[0],s[1])}}function eMr(){this.size=0,this.__data__={hash:new NLr,map:new(gae||b4e),string:new NLr}}function tMr(r){var t=typeof r;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?r!=="__proto__":r===null}function rMr(r,t){var a=r.__data__;return Fni(t)?a[typeof t=="string"?"string":"hash"]:a.map}function nMr(r){var t=v4e(this,r).delete(r);return this.size-=t?1:0,t}function iMr(r){return v4e(this,r).get(r)}function aMr(r){return v4e(this,r).has(r)}function sMr(r,t){var a=v4e(this,r),s=a.size;return a.set(r,t),this.size+=a.size==s?0:1,this}function lB(r){var t=-1,a=r==null?0:r.length;for(this.clear();++t<a;){var s=r[t];this.set(s[0],s[1])}}function oMr(r,t){var a=this.__data__;if(a instanceof b4e){var s=a.__data__;if(!gae||s.length<Uni-1)return s.push([r,t]),this.size=++a.size,this;a=this.__data__=new w4e(s)}return a.set(r,t),this.size=a.size,this}function cB(r){var t=this.__data__=new b4e(r);this.size=t.size}function lMr(r){return this.__data__.set(r,Wni),this}function cMr(r){return this.__data__.has(r)}function yae(r){var t=-1,a=r==null?0:r.length;for(this.__data__=new w4e;++t<a;)this.add(r[t])}function hMr(r,t){for(var a=-1,s=r==null?0:r.length;++a<s;)if(t(r[a],a,r))return!0;return!1}function fMr(r,t){return r.has(t)}function pMr(r,t,a,s,l,h){var f=a&Xni,d=r.length,m=t.length;if(d!=m&&!(f&&m>d))return!1;var b=h.get(r),v=h.get(t);if(b&&v)return b==t&&v==r;var T=-1,C=!0,E=a&Kni?new uMr:void 0;for(h.set(r,t),h.set(t,r);++T<d;){var S=r[T],R=t[T];if(s)var L=f?s(R,S,T,t,r,h):s(S,… line truncated, 19.3 kB in all
<${t}> may appears as a prefix path in all these alternatives.
`;return s=s+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
For Further details.`,s}function COr(r){if(r instanceof Bb)return"SUBRULE";if(r instanceof b1)return"OPTION";if(r instanceof k2)return"OR";if(r instanceof ux)return"AT_LEAST_ONE";if(r instanceof hx)return"AT_LEAST_ONE_SEP";if(r instanceof T2)return"MANY_SEP";if(r instanceof kp)return"MANY";if(r instanceof Af)return"CONSUME";throw Error("non exhaustive match")}function EOr(r,t,a){let s=Asi(t.configs.elements,h=>h.state.transitions),l=Gsi(s.filter(h=>h instanceof R4e).map(h=>h.tokenType),h=>h.tokenTypeIdx);return{actualToken:a,possibleTokenTypes:l,tokenPath:r}}function SOr(r,t){return r.edges[t.tokenTypeIdx]}function AOr(r,t,a){let s=new Dst,l=[];for(let f of r.elements){if(a.is(f.alt)===!1)continue;if(f.state.type===uB){l.push(f);continue}let d=f.state.transitions.length;for(let m=0;m<d;m++){let b=f.state.transitions[m],v=ROr(b,t);v!==void 0&&s.add({state:v,alt:f.alt,stack:f.stack})}}let h;if(l.length===0&&s.size===1&&(h=s),h===void 0){h=new Dst;for(let f of s.elements)bae(f,h)}if(l.length>0&&!IOr(h))for(let f of l)h.add(f);return h}function ROr(r,t){if(r instanceof R4e&&f4e(t,r.tokenType))return r.target}function LOr(r,t){let a;for(let s of r.elements)if(t.is(s.alt)===!0){if(a===void 0)a=s.alt;else if(a!==s.alt)return}return a}function jlt(r){return{configs:r,edges:{},isAcceptState:!1,prediction:-1}}function Nst(r,t,a,s){return s=zlt(r,s),t.edges[a.tokenTypeIdx]=s,s}function zlt(r,t){if(t===K3e)return t;let a=t.configs.key,s=r.states[a];return s!==void 0?s:(t.configs.finalize(),r.states[a]=t,t)}function _Or(r){let t=new Dst,a=r.transitions.length;for(let s=0;s<a;s++){let h={state:r.transitions[s].target,alt:s,stack:[]};bae(h,t)}return t}function bae(r,t){let a=r.state;if(a.type===uB){if(r.stack.length>0){let l=[...r.stack],f={state:l.pop(),alt:r.alt,stack:l};bae(f,t)}else t.add(r);return}a.epsilonOnlyTransitions||t.add(r);let s=a.transitions.length;for(let l=0;l<s;l++){let h=a.transitions[l],f=DOr(r,h);f!==void 0&&bae(f,t)}}function DOr(r,t){if(t instanceof DNr)return{state:t.target,alt:r.alt,stack:r.stack};if(t instanceof L4e){let a=[...r.stack,t.followState];return{state:t.target,alt:r.alt,stack:a}}}function IOr(r){for(let t of r.elements)if(t.state.type===uB)return!0;return!1}function MOr(r){for(let t of r.elements)if(t.state.type!==uB)return!1;return!0}function NOr(r){if(MOr(r))return!0;let t=OOr(r.elements);return POr(t)&&!BOr(t)}function OOr(r){let t=new Map;for(let a of r){let s=$lt(a,!1),l=t.get(s);l===void 0&&(l={},t.set(s,l)),l[a.alt]=!0}return t}function POr(r){for(let t of Array.from(r.values()))if(Object.keys(t).length>1)return!0;return!1}function BOr(r){for(let t of Array.from(r.values()))if(Object.keys(t).length===1)return!0;return!1}function FOr(r,t){let a;for(let s of r.configs.elements)if(!(t.is(s.alt)===!1||s.state.type===uB)){if(a===void 0)a=s.alt;else if(a!==s.alt)return}return a}function $P(r){return r|0}function k3e(r){return r.$type===Ost}function Vlt(r,t,a){return qOr({parser:t,tokens:a,ruleNames:new Map},r),t}function qOr(r,t){let a=Zot(t,!1),s=rd(t.rules).filter(qS).filter(h=>a.has(h));for(let h of s){let f={...r,consume:1,optional:1,subrule:1,many:1,or:1};r.parser.rule(h,CD(f,h.definition))}let l=rd(t.rules).filter(cae).filter(h=>a.has(h));for(let h of l)r.parser.rule(h,YOr(r,h))}function YOr(r,t){let a=t.call.rule.ref;if(!a)throw new Error("Could not resolve reference to infix operator rule: "+t.call.rule.$refText);if(YS(a))throw new Error("Cannot use terminal rule in infix expression");let s=t.operators.precedences.flatMap(E=>E.operators),l={$type:"Group",elements:[]},h={$container:l,$type:"Assignment",feature:"parts",operator:"+=",terminal:t.call},f={$container:l,$type:"Group",elements:[],cardinality:"*"};l.elements.push(h,f);let m={$container:f,$type:"Assignment",feature:"operators",operator:"+=",terminal:{$type:"Alternatives",elements:s}},b={...h,$container:f};f.elements.push(m,b);let T=s.map(E=>r.tokens[E.value]).map((E,S)=>({ALT:J(()=>r.parser.consume(S,E,m),"ALT")})),C;return E=>{C??(C=I4e(r,a)),r.parser.subrule(0,C,!1,h,E),r.parser.many(0,{DEF:J(()=>{r.parser.alternatives(0,T),r.parse… line truncated, 15.0 kB in all
`)?`
`:`
`}function hu(r){return{documentation:{CommentProvider:J(t=>new Foi(t),"CommentProvider"),DocumentationProvider:J(t=>new Boi(t),"DocumentationProvider")},parser:{AsyncParser:J(t=>new $oi(t),"AsyncParser"),GrammarConfig:J(t=>ODr(t),"GrammarConfig"),LangiumParser:J(t=>iPr(t),"LangiumParser"),CompletionParser:J(t=>nPr(t),"CompletionParser"),ValueConverter:J(()=>new oPr,"ValueConverter"),TokenBuilder:J(()=>new sPr,"TokenBuilder"),Lexer:J(t=>new Moi(t),"Lexer"),ParserErrorMessageProvider:J(()=>new WOr,"ParserErrorMessageProvider"),LexerErrorMessageProvider:J(()=>new Doi,"LexerErrorMessageProvider")},workspace:{AstNodeLocator:J(()=>new Eoi,"AstNodeLocator"),AstNodeDescriptionProvider:J(t=>new koi(t),"AstNodeDescriptionProvider"),ReferenceDescriptionProvider:J(t=>new Coi(t),"ReferenceDescriptionProvider")},references:{Linker:J(t=>new coi(t),"Linker"),NameProvider:J(()=>new uoi,"NameProvider"),ScopeProvider:J(t=>new yoi(t),"ScopeProvider"),ScopeComputation:J(t=>new foi(t),"ScopeComputation"),References:J(t=>new hoi(t),"References")},serializer:{Hydrator:J(t=>new joi(t),"Hydrator"),JsonSerializer:J(t=>new boi(t),"JsonSerializer")},validation:{DocumentValidator:J(t=>new Toi(t),"DocumentValidator"),ValidationRegistry:J(t=>new woi(t),"ValidationRegistry")},shared:J(()=>r.shared,"shared")}}function fu(r){return{ServiceRegistry:J(t=>new voi(t),"ServiceRegistry"),workspace:{LangiumDocuments:J(t=>new soi(t),"LangiumDocuments"),LangiumDocumentFactory:J(t=>new aoi(t),"LangiumDocumentFactory"),DocumentBuilder:J(t=>new Roi(t),"DocumentBuilder"),IndexManager:J(t=>new Loi(t),"IndexManager"),WorkspaceManager:J(t=>new _oi(t),"WorkspaceManager"),FileSystemProvider:J(t=>r.fileSystemProvider(t),"FileSystemProvider"),WorkspaceLock:J(()=>new Goi,"WorkspaceLock"),ConfigurationProvider:J(t=>new Aoi(t),"ConfigurationProvider")},profilers:{}}}function _o(r,t,a,s,l,h,f,d,m){let b=[r,t,a,s,l,h,f,d,m].reduce(eW,{});return tct(b)}function tct(r,t){let a=new Proxy({},{deleteProperty:J(()=>!1,"deleteProperty"),set:J(()=>{throw new Error("Cannot set property on injected service container")},"set"),get:J((s,l)=>l===zoi?!0:Vst(s,l,r,t||a),"get"),getOwnPropertyDescriptor:J((s,l)=>(Vst(s,l,r,t||a),Object.getOwnPropertyDescriptor(s,l)),"getOwnPropertyDescriptor"),has:J((s,l)=>l in r,"has"),ownKeys:J(()=>[...Object.getOwnPropertyNames(r)],"ownKeys")});return a}function Vst(r,t,a,s){if(t in r){if(r[t]instanceof Error)throw new Error("Construction failure. Please make sure that your dependencies are constructable. Cause: "+r[t]);if(r[t]===u_r)throw new Error('Cycle detected. Please make "'+String(t)+'" lazy. Visit https://langium.org/docs/reference/configuration-services/#resolving-cyclic-dependencies');return r[t]}else if(t in a){let l=a[t];r[t]=u_r;try{r[t]=typeof l=="function"?l(s):tct(l,s)}catch(h){throw r[t]=h instanceof Error?h:void 0,h}return r[t]}else return}function eW(r,t){if(t){for(let[a,s]of Object.entries(t))if(!(a==="__proto__"||a==="constructor"||a==="prototype")&&s!=null)if(typeof s=="object"){let l=r[a];typeof l=="object"&&l!==null?r[a]=eW(l,s):r[a]=eW({},s)}else r[a]=s}return r}function _Pr(){let r=_o(fu(Lu),Woi),t=_o(hu({shared:r}),Voi);return r.ServiceRegistry.register(t),t}function Cy(r){let t=_Pr(),a=t.serializer.JsonSerializer.deserialize(r);return t.shared.workspace.LangiumDocumentFactory.fromModel(a,cx.parse(`memory:/${a.name??"grammar"}.langium`)),a}function DPr(r){return sg.isInstance(r,K4.$type)}function IPr(r){return sg.isInstance(r,iae.$type)}function MPr(r){return sg.isInstance(r,VP.$type)}function NPr(r){return sg.isInstance(r,mD.$type)}function OPr(r){return sg.isInstance(r,aae.$type)}function PPr(r){return sg.isInstance(r,t4e.$type)}function BPr(r){return r==="rmo"||r==="readmodel"||r==="ui"||r==="cmd"||r==="command"||r==="evt"||r==="event"||r==="pcr"||r==="processor"}function N4e(r){return sg.isInstance(r,a8.$type)}function FPr(r){return sg.isInstance(r,yD.$type)}function $Pr(r){return sg.isInstance(r,qV.$type)}function GPr(r){return sg.isInstance(r,WP.$type)}function jPr(r){return sg.isInstance(r,HP.$type)}function zPr(r){return sg.… line truncated, 33.4 kB in all
${JSON.stringify(Object.fromEntries(R))}`));return}let _=parseInt(L);if(isNaN(_)){this.fireError(new Error(`Content-Length value must be a number. Got ${L}`));return}this.nextMessageLength=_}let S=this.buffer.tryReadBody(this.nextMessageLength);if(S===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let R=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(S):S,L=await this.options.contentTypeDecoder.decode(R,this.options);this.callback(L)}).catch(R=>{this.fireError(R)})}}catch(S){this.fireError(S)}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,h.default)().timer.setTimeout((E,S)=>{this.partialMessageTimer=void 0,E===this.messageToken&&(this.firePartialMessage({messageToken:E,waitingTime:S}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}};r.ReadableStreamMessageReader=C}}),Eti=Cl({"../../node_modules/.pnpm/vscode-jsonrpc@9.0.3/node_modules/vscode-jsonrpc/lib/common/messageWriter.js"(r){"use strict";var t=r&&r.__createBinding||(Object.create?(function(R,L,_,I){I===void 0&&(I=_);var N=Object.getOwnPropertyDescriptor(L,_);(!N||("get"in N?!L.__esModule:N.writable||N.configurable))&&(N={enumerable:!0,get:J(function(){return L[_]},"get")}),Object.defineProperty(R,I,N)}):(function(R,L,_,I){I===void 0&&(I=_),R[I]=L[_]})),a=r&&r.__setModuleDefault||(Object.create?(function(R,L){Object.defineProperty(R,"default",{enumerable:!0,value:L})}):function(R,L){R.default=L}),s=r&&r.__importStar||(function(){var R=J(function(L){return R=Object.getOwnPropertyNames||function(_){var I=[];for(var N in _)Object.prototype.hasOwnProperty.call(_,N)&&(I[I.length]=N);return I},R(L)},"ownKeys");return function(L){if(L&&L.__esModule)return L;var _={};if(L!=null)for(var I=R(L),N=0;N<I.length;N++)I[N]!=="default"&&t(_,L,I[N]);return a(_,L),_}})(),l=r&&r.__importDefault||function(R){return R&&R.__esModule?R:{default:R}};Object.defineProperty(r,"__esModule",{value:!0}),r.WriteableStreamMessageWriter=r.AbstractMessageWriter=r.MessageWriter=void 0;var h=l(nB()),f=s(Tae()),d=O_r(),m=kae(),b="Content-Length: ",v=`\r
`,T;(function(R){function L(_){let I=_;return I&&f.func(I.dispose)&&f.func(I.onClose)&&f.func(I.onError)&&f.func(I.write)}i(L,"is"),J(L,"is"),R.is=L})(T||(r.MessageWriter=T={}));var C=class{static{i(this,"AbstractMessageWriter")}static{J(this,"AbstractMessageWriter")}errorEmitter;closeEmitter;constructor(){this.errorEmitter=new m.Emitter,this.closeEmitter=new m.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(R,L,_){this.errorEmitter.fire([this.asError(R),L,_])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(R){return R instanceof Error?R:new Error(`Writer received error. Reason: ${f.string(R.message)?R.message:"unknown"}`)}};r.AbstractMessageWriter=C;var E;(function(R){function L(_){return _===void 0||typeof _=="string"?{charset:_??"utf-8",contentTypeEncoder:(0,h.default)().applicationJson.encoder}:{charset:_.charset??"utf-8",contentEncoder:_.contentEncoder,contentTypeEncoder:_.contentTypeEncoder??(0,h.default)().applicationJson.encoder}}i(L,"fromOptions"),J(L,"fromOptions"),R.fromOptions=L})(E||(E={}));var S=class extends C{static{i(this,"WriteableStreamMessageWriter")}static{J(this,"WriteableStreamMessageWriter")}writable;options;errorCount;writeSemaphore;constructor(R,L){super(),this.writable=R,this.options=E.fromOptions(L),this.errorCount=0,this.writeSemaphore=new d.Semaphore(1),this.writable.onError(_=>this.fireError(_)),this.writable.onClose(()=>this.fireClose())}async write(R){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(R,this.options).then(_=>this.options.contentEncoder!==void 0?this.options.contentEncoder.encode(_):_).then(_=>{let I=[];return I.push(b,_.byteLength.toString(),v),I.push(v),this.doWrite(R,I,_)},_=>{throw this.fireError(_),_}))}async doWrite(R,L,_){try{return await this.writable.write(L.join(""),"ascii"),this.writable.write(_)}catch(I){return this.handleError(I,R),Promise.reject(I)}}handleError(R,L){this.errorCount++,this.fireError(R,L,this.errorCount)}end(){this.writable.end()}};r.WriteableStreamMessageWriter=S}}),Sti=Cl({"../../node_modules/.pnpm/vscode-jsonrpc@9.0.3/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js"(r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.AbstractMessageBuffer=void 0;var t=13,a=10,s=`\r
`,l=class{static{i(this,"AbstractMessageBuffer")}static{J(this,"AbstractMessageBuffer")}_encoding;_chunks;_totalLength;constructor(h="utf-8"){this._encoding=h,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(h){let f=typeof h=="string"?this.fromString(h,this._encoding):h;this._chunks.push(f),this._totalLength+=f.byteLength}tryReadHeaders(h=!1){if(this._chunks.length===0)return;let f=0,d=0,m=0,b=0;e:for(;d<this._chunks.length;){let E=this._chunks[d];for(m=0;m<E.length;){switch(E[m]){case t:switch(f){case 0:f=1;break;case 2:f=3;break;default:f=0}break;case a:switch(f){case 1:f=2;break;case 3:f=4,m++;break e;default:f=0}break;default:f=0}m++}b+=E.byteLength,d++}if(f!==4)return;let v=this._read(b+m),T=new Map,C=this.toString(v,"ascii").split(s);if(C.length<2)return T;for(let E=0;E<C.length-2;E++){let S=C[E],R=S.indexOf(":");if(R===-1)throw new Error(`Message header must separate key and value using ':'
${S}`);let L=S.substr(0,R),_=S.substr(R+1).trim();T.set(h?L.toLowerCase():L,_)}return T}tryReadBody(h){if(!(this._totalLength<h))return this._read(h)}get numberOfBytes(){return this._totalLength}_read(h){if(h===0)return this.emptyBuffer();if(h>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===h){let b=this._chunks[0];return this._chunks.shift(),this._totalLength-=h,this.asNative(b)}if(this._chunks[0].byteLength>h){let b=this._chunks[0],v=this.asNative(b,h);return this._chunks[0]=b.slice(h),this._totalLength-=h,v}let f=this.allocNative(h),d=0,m=0;for(;h>0;){let b=this._chunks[m];if(b.byteLength>h){let v=b.slice(0,h);f.set(v,d),d+=h,this._chunks[m]=b.slice(h),this._totalLength-=h,h-=h}else f.set(b,d),d+=b.byteLength,this._chunks.shift(),this._totalLength-=b.byteLength,h-=b.byteLength}return f}};r.AbstractMessageBuffer=l}}),Ati=Cl({"../../node_modules/.pnpm/vscode-jsonrpc@9.0.3/node_modules/vscode-jsonrpc/lib/common/connection.js"(r){"use strict";var t=r&&r.__createBinding||(Object.create?(function(te,U,ne,se){se===void 0&&(se=ne);var he=Object.getOwnPropertyDescriptor(U,ne);(!he||("get"in he?!U.__esModule:he.writable||he.configurable))&&(he={enumerable:!0,get:J(function(){return U[ne]},"get")}),Object.defineProperty(te,se,he)}):(function(te,U,ne,se){se===void 0&&(se=ne),te[se]=U[ne]})),a=r&&r.__setModuleDefault||(Object.create?(function(te,U){Object.defineProperty(te,"default",{enumerable:!0,value:U})}):function(te,U){te.default=U}),s=r&&r.__importStar||(function(){var te=J(function(U){return te=Object.getOwnPropertyNames||function(ne){var se=[];for(var he in ne)Object.prototype.hasOwnProperty.call(ne,he)&&(se[se.length]=he);return se},te(U)},"ownKeys");return function(U){if(U&&U.__esModule)return U;var ne={};if(U!=null)for(var se=te(U),he=0;he<se.length;he++)se[he]!=="default"&&t(ne,U,se[he]);return a(ne,U),ne}})(),l=r&&r.__importDefault||function(te){return te&&te.__esModule?te:{default:te}};Object.defineProperty(r,"__esModule",{value:!0}),r.ConnectionOptions=r.MessageStrategy=r.CancellationStrategy=r.CancellationSenderStrategy=r.CancellationReceiverStrategy=r.RequestCancellationReceiverStrategy=r.IdCancellationReceiverStrategy=r.ConnectionStrategy=r.ConnectionError=r.ConnectionErrors=r.LogTraceNotification=r.SetTraceNotification=r.TraceFormat=r.TraceValues=r.TraceValue=r.Trace=r.NullLogger=r.ProgressType=r.ProgressToken=void 0,r.createMessageConnection=X;var h=l(nB()),f=s(Tae()),d=D_r(),m=M_r(),b=kae(),v=zot(),T;(function(te){te.type=new d.NotificationType("$/cancelRequest")})(T||(T={}));var C;(function(te){function U(ne){return typeof ne=="string"||typeof ne=="number"}i(U,"is"),J(U,"is"),te.is=U})(C||(r.ProgressToken=C={}));var E;(function(te){te.type=new d.NotificationType("$/progress")})(E||(E={}));var S=class{static{i(this,"ProgressType")}static{J(this,"ProgressType")}__;_pr;constructor(){}};r.ProgressType=S;var R;(function(te){function U(ne){return f.func(ne)}i(U,"is"),J(U,"is"),te.is=U})(R||(R={})),r.NullLogger=Object.freeze({error:J(()=>{},"error"),warn:J(()=>{},"warn"),info:J(()=>{},"info"),log:J(()=>{},"log")});var L;(function(te){te[te.Off=0]="Off",te[te.Messages=1]="Messages",te[te.Compact=2]="Compact",te[te.Verbose=3]="Verbose"})(L||(r.Trace=L={}));var _;(function(te){te.Off="off",te.Messages="messages",te.Compact="compact",te.Verbose="verbose"})(_||(r.TraceValue=_={})),r.TraceValues=_,(function(te){function U(se){if(!f.string(se))return te.Off;switch(se=se.toLowerCase(),se){case"off":return te.Off;case"messages":return te.Messages;case"compact":return te.Compact;case"verbose":return te.Verbose;default:return te.Off}}i(U,"fromString"),J(U,"fromString"),te.fromString=U;function ne(se){switch(se){case te.Off:return"off";case te.Messages:return"messages";case te.Compact:return"compact";case te.Verbose:return"verbose";default:return"off"}}i(ne,"toString3"),J(ne,"toString"),te.toString=ne})(L||(r.Trace=L={}));var I;(function(te){te.Text="text",te.JSON="json"})(I||(r.TraceFormat=I={})),(function(te){function U(ne){return f.string(ne)?(ne=ne.toLowerCase(),ne==="json"?te… line truncated, 11.6 kB in all
${JSON.stringify(ct.error,void 0,4)}`):he.error("Received response message without id. No further error information provided.");else{let dr=ct.id,Kr=Ft.get(dr);if(Un(ct,Kr),Kr!==void 0){Ft.delete(dr);try{if(ct.error){let pn=ct.error;Kr.reject(new d.ResponseError(pn.code,pn.message,pn.data))}else if(ct.result!==void 0)Kr.resolve(ct.result);else throw new Error("Should never happen.")}catch(pn){pn.message?he.error(`Response handler '${Kr.method}' failed with message: ${pn.message}`):he.error(`Response handler '${Kr.method}' failed unexpectedly.`)}}}}i($t,"handleResponse"),J($t,"handleResponse");async function qt(ct){if(ce())return;let dr,Kr;if(ct.method===T.type.method){let pn=ct.params.id;pr.delete(pn),An(ct);return}else{let pn=Fe.get(ct.method);pn&&(Kr=pn.handler,dr=pn.type)}if(Kr||Be)try{if(An(ct),Kr)if(ct.params===void 0)dr!==void 0&&dr.numberOfParams!==0&&dr.parameterStructures!==d.ParameterStructures.byName&&he.error(`Notification ${ct.method} defines ${dr.numberOfParams} params but received none.`),await Kr();else if(Array.isArray(ct.params)){let pn=ct.params;ct.method===E.type.method&&pn.length===2&&C.is(pn[0])?await Kr({token:pn[0],value:pn[1]}):(dr!==void 0&&(dr.parameterStructures===d.ParameterStructures.byName&&he.error(`Notification ${ct.method} defines parameters by name but received parameters by position`),dr.numberOfParams!==ct.params.length&&he.error(`Notification ${ct.method} defines ${dr.numberOfParams} params but received ${pn.length} arguments`)),await Kr(...pn))}else dr!==void 0&&dr.parameterStructures===d.ParameterStructures.byPosition&&he.error(`Notification ${ct.method} defines parameters by position but received parameters by name`),await Kr(ct.params);else Be&&await Be(ct.method,ct.params)}catch(pn){pn.message?he.error(`Notification handler '${ct.method}' failed with message: ${pn.message}`):he.error(`Notification handler '${ct.method}' failed unexpectedly.`)}else gt.fire(ct)}i(qt,"handleNotification"),J(qt,"handleNotification");function Gt(ct){if(!ct){he.error("Received empty message.");return}he.error(`Received message which is neither a response nor a notification message:
${JSON.stringify(ct,null,4)}`);let dr=ct;if(f.string(dr.id)||f.number(dr.id)){let Kr=dr.id,pn=Ft.get(Kr);pn&&pn.reject(new Error("The received response has neither a result nor an error property."))}}i(Gt,"handleInvalidMessage"),J(Gt,"handleInvalidMessage");function jt(ct){if(ct!=null)switch(Mt){case L.Verbose:return JSON.stringify(ct,null,4);case L.Compact:return JSON.stringify(ct);default:return}}i(jt,"stringifyTrace"),J(jt,"stringifyTrace");function Zr(ct){if(!(Mt===L.Off||!it))if(ot===I.Text){let dr;(Mt===L.Verbose||Mt===L.Compact)&&ct.params&&(dr=`Params: ${jt(ct.params)}`),it.log(`Sending request '${ct.method} - (${ct.id})'.`,dr)}else En("send-request",ct)}i(Zr,"traceSendingRequest"),J(Zr,"traceSendingRequest");function yt(ct){if(!(Mt===L.Off||!it))if(ot===I.Text){let dr;(Mt===L.Verbose||Mt===L.Compact)&&(ct.params?dr=`Params: ${jt(ct.params)}`:dr="No parameters provided."),it.log(`Sending notification '${ct.method}'.`,dr)}else En("send-notification",ct)}i(yt,"traceSendingNotification"),J(yt,"traceSendingNotification");function $n(ct,dr,Kr){if(!(Mt===L.Off||!it))if(ot===I.Text){let pn;(Mt===L.Verbose||Mt===L.Compact)&&(ct.error&&ct.error.data?pn=`Error data: ${jt(ct.error.data)}`:ct.result?pn=`Result: ${jt(ct.result)}`:ct.error===void 0&&(pn="No result returned."));let Bn=ct.error?` Request failed: ${ct.error.message} (${ct.error.code}).`:"";it.log(`Sending response '${dr} - (${ct.id})'. Processing request took ${Date.now()-Kr}ms.${Bn}`,pn)}else En("send-response",ct)}i($n,"traceSendingResponse"),J($n,"traceSendingResponse");function Ut(ct){if(!(Mt===L.Off||!it))if(ot===I.Text){let dr;(Mt===L.Verbose||Mt===L.Compact)&&ct.params&&(dr=`Params: ${jt(ct.params)}`),it.log(`Received request '${ct.method} - (${ct.id})'.`,dr)}else En("receive-request",ct)}i(Ut,"traceReceivedRequest"),J(Ut,"traceReceivedRequest");function An(ct){if(!(Mt===L.Off||!it||ct.method===B.type.method))if(ot===I.Text){let dr;(Mt===L.Verbose||Mt===L.Compact)&&(ct.params?dr=`Params: ${jt(ct.params)}`:dr="No parameters provided."),it.log(`Received notification '${ct.method}'.`,dr)}else En("receive-notification",ct)}i(An,"traceReceivedNotification"),J(An,"traceReceivedNotification");function Un(ct,dr){if(!(Mt===L.Off||!it))if(ot===I.Text){let Kr;if((Mt===L.Verbose||Mt===L.Compact)&&(ct.error&&ct.error.data?Kr=`Error data: ${jt(ct.error.data)}`:ct.result?Kr=`Result: ${jt(ct.result)}`:ct.error===void 0&&(Kr="No result returned.")),dr){let pn=ct.error?` Request failed: ${ct.error.message} (${ct.error.code}).`:"";it.log(`Received response '${dr.method} - (${ct.id})' in ${Date.now()-dr.timerStart}ms.${pn}`,Kr)}else it.log(`Received response ${ct.id} without active response promise.`,Kr)}else En("receive-response",ct)}i(Un,"traceReceivedResponse"),J(Un,"traceReceivedResponse");function En(ct,dr){if(!it||Mt===L.Off)return;let Kr={isLSPMessage:!0,type:ct,message:dr,timestamp:Date.now()};it.log(Kr)}i(En,"logLSPMessage"),J(En,"logLSPMessage");function ai(){if(Te())throw new P(O.Closed,"Connection is closed.");if(ce())throw new P(O.Disposed,"Connection is disposed.")}i(ai,"throwIfClosedOrDisposed"),J(ai,"throwIfClosedOrDisposed");function Gn(){if(K())throw new P(O.AlreadyListening,"Connection is already listening")}i(Gn,"throwIfListening"),J(Gn,"throwIfListening");function ui(){if(!K())throw new Error("Call listen() first.")}i(ui,"throwIfNotListening"),J(ui,"throwIfNotListening");function Tn(ct){return ct===void 0?null:ct}i(Tn,"undefinedToNull"),J(Tn,"undefinedToNull");function Wi(ct){if(ct!==null)return ct}i(Wi,"nullToUndefined"),J(Wi,"nullToUndefined");function Pa(ct){return ct!=null&&!Array.isArray(ct)&&typeof ct=="object"}i(Pa,"isNamedParam"),J(Pa,"isNamedParam");function qe(ct,dr){switch(ct){case d.ParameterStructures.auto:return Pa(dr)?Wi(dr):[Tn(dr)];case d.ParameterStructures.byName:if(!Pa(dr))throw new Error("Received parameters by name but param is not an object literal.");return Wi(dr);case d.ParameterStructures.byPosition:return[Tn(dr)];default:throw new Error(`Unknown parameter structure ${ct.toString()}`)}}i(qe,"computeSingleParam"),J(qe,"computeSing… line truncated, 46.3 kB in all
`,`\r
`,"\r"],(function(r){function t(h,f,d,m){return new uLr(h,f,d,m)}i(t,"create"),J(t,"create"),r.create=t;function a(h){let f=h;return!!(jr.defined(f)&&jr.string(f.uri)&&(jr.undefined(f.languageId)||jr.string(f.languageId))&&jr.uinteger(f.lineCount)&&jr.func(f.getText)&&jr.func(f.positionAt)&&jr.func(f.offsetAt))}i(a,"is"),J(a,"is"),r.is=a;function s(h,f){let d=h.getText(),m=l(f,(v,T)=>{let C=v.range.start.line-T.range.start.line;return C===0?v.range.start.character-T.range.start.character:C}),b=d.length;for(let v=m.length-1;v>=0;v--){let T=m[v],C=h.offsetAt(T.range.start),E=h.offsetAt(T.range.end);if(E<=b)d=d.substring(0,C)+T.newText+d.substring(E,d.length);else throw new Error("Overlapping edit");b=C}return d}i(s,"applyEdits"),J(s,"applyEdits"),r.applyEdits=s;function l(h,f){if(h.length<=1)return h;let d=h.length/2|0,m=h.slice(0,d),b=h.slice(d);l(m,f),l(b,f);let v=0,T=0,C=0;for(;v<m.length&&T<b.length;)f(m[v],b[T])<=0?h[C++]=m[v++]:h[C++]=b[T++];for(;v<m.length;)h[C++]=m[v++];for(;T<b.length;)h[C++]=b[T++];return h}i(l,"mergeSort2"),J(l,"mergeSort")})(Qat||(Qat={})),uLr=class{static{i(this,"FullTextDocument")}static{J(this,"FullTextDocument")}constructor(r,t,a,s){this._uri=r,this._languageId=t,this._version=a,this._content=s,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(r){if(r){let t=this.offsetAt(r.start),a=this.offsetAt(r.end);return this._content.substring(t,a)}return this._content}update(r,t){this._content=r.text,this._version=t,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let r=[],t=this._content,a=!0;for(let s=0;s<t.length;s++){a&&(r.push(s),a=!1);let l=t.charAt(s);a=l==="\r"||l===`
`,l==="\r"&&s+1<t.length&&t.charAt(s+1)===`
`&&s++}a&&t.length>0&&r.push(t.length),this._lineOffsets=r}return this._lineOffsets}positionAt(r){r=Math.max(Math.min(r,this._content.length),0);let t=this.getLineOffsets(),a=0,s=t.length;if(s===0)return ch.create(0,r);for(;a<s;){let h=Math.floor((a+s)/2);t[h]>r?s=h:a=h+1}let l=a-1;return ch.create(l,r-t[l])}offsetAt(r){let t=this.getLineOffsets();if(r.line>=t.length)return this._content.length;if(r.line<0)return 0;let a=t[r.line],s=r.line+1<t.length?t[r.line+1]:this._content.length;return Math.max(Math.min(a+r.character,s),a)}get lineCount(){return this.getLineOffsets().length}},(function(r){let t=Object.prototype.toString;function a(E){return typeof E<"u"}i(a,"defined"),J(a,"defined"),r.defined=a;function s(E){return typeof E>"u"}i(s,"undefined2"),J(s,"undefined"),r.undefined=s;function l(E){return E===!0||E===!1}i(l,"boolean"),J(l,"boolean"),r.boolean=l;function h(E){return t.call(E)==="[object String]"}i(h,"string"),J(h,"string"),r.string=h;function f(E){return t.call(E)==="[object Number]"}i(f,"number"),J(f,"number"),r.number=f;function d(E,S,R){return t.call(E)==="[object Number]"&&S<=E&&E<=R}i(d,"numberRange"),J(d,"numberRange"),r.numberRange=d;function m(E){return t.call(E)==="[object Number]"&&-2147483648<=E&&E<=2147483647}i(m,"integer2"),J(m,"integer"),r.integer=m;function b(E){return t.call(E)==="[object Number]"&&0<=E&&E<=2147483647}i(b,"uinteger2"),J(b,"uinteger"),r.uinteger=b;function v(E){return t.call(E)==="[object Function]"}i(v,"func"),J(v,"func"),r.func=v;function T(E){return E!==null&&typeof E=="object"}i(T,"objectLiteral"),J(T,"objectLiteral"),r.objectLiteral=T;function C(E,S){return Array.isArray(E)&&E.every(S)}i(C,"typedArray"),J(C,"typedArray"),r.typedArray=C})(jr||(jr={}))}}),nd=Cl({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.18.4/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.CM=r.ProtocolNotificationType=r.ProtocolNotificationType0=r.ProtocolRequestType=r.ProtocolRequestType0=r.RegistrationType=r.MessageDirection=void 0;var t=Cae(),a;(function(b){b.clientToServer="clientToServer",b.serverToClient="serverToClient",b.both="both"})(a||(r.MessageDirection=a={}));var s=class{static{i(this,"RegistrationType")}static{J(this,"RegistrationType")}____;method;constructor(b){this.method=b}};r.RegistrationType=s;var l=class extends t.RequestType0{static{i(this,"ProtocolRequestType0")}static{J(this,"ProtocolRequestType0")}__;___;____;_pr;constructor(b){super(b)}};r.ProtocolRequestType0=l;var h=class extends t.RequestType{static{i(this,"ProtocolRequestType")}static{J(this,"ProtocolRequestType")}__;___;____;_pr;constructor(b){super(b,t.ParameterStructures.byName)}};r.ProtocolRequestType=h;var f=class extends t.NotificationType0{static{i(this,"ProtocolNotificationType0")}static{J(this,"ProtocolNotificationType0")}___;____;constructor(b){super(b)}};r.ProtocolNotificationType0=f;var d=class extends t.NotificationType{static{i(this,"ProtocolNotificationType")}static{J(this,"ProtocolNotificationType")}___;____;constructor(b){super(b,t.ParameterStructures.byName)}};r.ProtocolNotificationType=d;var m;(function(b){function v(T,C){return{client:T,server:C}}i(v,"create"),J(v,"create"),b.create=v})(m||(r.CM=m={}))}}),Uot=Cl({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.18.4/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.boolean=t,r.string=a,r.number=s,r.error=l,r.func=h,r.array=f,r.stringArray=d,r.typedArray=m,r.objectLiteral=b;function t(v){return v===!0||v===!1}i(t,"boolean"),J(t,"boolean");function a(v){return typeof v=="string"||v instanceof String}i(a,"string"),J(a,"string");function s(v){return typeof v=="number"||v instanceof Number}i(s,"number"),J(s,"number");function l(v){return v instanceof Error}i(l,"error"),J(l,"error");function h(v){return typeof v=="function"}i(h,"func"),J(h,"func");function f(v){return Array.isArray(v)}i(f,"array"),J(f,"array");function d(v){return f(v)&&v.every(T=>a(T))}i(d,"stringArray"… line truncated, 79.6 kB in all
`),Eo("\r"),Eo(" "),Eo("\v"),Eo(" "),Eo("\xA0"),Eo("\u1680"),Eo("\u2000"),Eo("\u2001"),Eo("\u2002"),Eo("\u2003"),Eo("\u2004"),Eo("\u2005"),Eo("\u2006"),Eo("\u2007"),Eo("\u2008"),Eo("\u2009"),Eo("\u200A"),Eo("\u2028"),Eo("\u2029"),Eo("\u202F"),Eo("\u205F"),Eo("\u3000"),Eo("\uFEFF")],Zti=/[0-9a-fA-F]/,Oke=/[0-9]/,eri=/[1-9]/,mDr=class{static{i(this,"RegExpParser")}static{J(this,"RegExpParser")}constructor(){this.idx=0,this.input="",this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(r){this.idx=r.idx,this.input=r.input,this.groupIdx=r.groupIdx}pattern(r){this.idx=0,this.input=r,this.groupIdx=0,this.consumeChar("/");let t=this.disjunction();this.consumeChar("/");let a={type:"Flags",loc:{begin:this.idx,end:r.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case"g":FV(a,"global");break;case"i":FV(a,"ignoreCase");break;case"m":FV(a,"multiLine");break;case"u":FV(a,"unicode");break;case"y":FV(a,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:a,value:t,loc:this.loc(0)}}disjunction(){let r=[],t=this.idx;for(r.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),r.push(this.alternative());return{type:"Disjunction",value:r,loc:this.loc(t)}}alternative(){let r=[],t=this.idx;for(;this.isTerm();)r.push(this.term());return{type:"Alternative",value:r,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let r=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(r)};case"$":return{type:"EndAnchor",loc:this.loc(r)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(r)};case"B":return{type:"NonWordBoundary",loc:this.loc(r)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");let t;switch(this.popChar()){case"=":t="Lookahead";break;case"!":t="NegativeLookahead";break;case"<":{switch(this.popChar()){case"=":t="Lookbehind";break;case"!":t="NegativeLookbehind"}break}}BP(t);let a=this.disjunction();return this.consumeChar(")"),{type:t,value:a,loc:this.loc(r)}}return Yie()}quantifier(r=!1){let t,a=this.idx;switch(this.popChar()){case"*":t={atLeast:0,atMost:1/0};break;case"+":t={atLeast:1,atMost:1/0};break;case"?":t={atLeast:0,atMost:1};break;case"{":let s=this.integerIncludingZero();switch(this.popChar()){case"}":t={atLeast:s,atMost:s};break;case",":let l;this.isDigit()?(l=this.integerIncludingZero(),t={atLeast:s,atMost:l}):t={atLeast:s,atMost:1/0},this.consumeChar("}");break}if(r===!0&&t===void 0)return;BP(t);break}if(!(r===!0&&t===void 0)&&BP(t))return this.peekChar(0)==="?"?(this.consumeChar("?"),t.greedy=!1):t.greedy=!0,t.type="Quantifier",t.loc=this.loc(a),t}atom(){let r,t=this.idx;switch(this.peekChar()){case".":r=this.dotAll();break;case"\\":r=this.atomEscape();break;case"[":r=this.characterClass();break;case"(":r=this.group();break}return r===void 0&&this.isPatternCharacter()&&(r=this.patternCharacter()),BP(r)?(r.loc=this.loc(t),this.isQuantifier()&&(r.quantifier=this.quantifier()),r):Yie()}dotAll(){return this.consumeChar("."),{type:"Set",complement:!0,value:[Eo(`
`),Eo("\r"),Eo("\u2028"),Eo("\u2029")]}}atomEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:"GroupBackReference",value:this.positiveInteger()}}characterClassEscape(){let r,t=!1;switch(this.popChar()){case"d":r=G3e;break;case"D":r=G3e,t=!0;break;case"s":r=bLr;break;case"S":r=bLr,t=!0;break;case"w":r=j3e;break;case"W":r=j3e,t=!0;break}return BP(r)?{type:"Set",value:r,complement:t}:Yie()}controlEscapeAtom(){let r;switch(this.popChar()){case"f":r=Eo("\f");break;case"n":r=Eo(`
`);break;case"r":r=Eo("\r");break;case"t":r=Eo(" ");break;case"v":r=Eo("\v");break}return BP(r)?{type:"Character",value:r}:Yie()}controlLetterEscapeAtom(){this.consumeChar("c");let r=this.popChar();if(/[a-zA-Z]/.test(r)===!1)throw Error("Invalid ");return{type:"Character",value:r.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar("0"),{type:"Character",value:Eo("\0")}}hexEscapeSequenceAtom(){return this.consumeChar("x"),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar("u"),this.parseHexDigits(4)}identityEscapeAtom(){let r=this.popChar();return{type:"Character",value:Eo(r)}}classPatternCharacterAtom(){switch(this.peekChar()){case`
`:case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:let r=this.popChar();return{type:"Character",value:Eo(r)}}}characterClass(){let r=[],t=!1;for(this.consumeChar("["),this.peekChar(0)==="^"&&(this.consumeChar("^"),t=!0);this.isClassAtom();){let a=this.classAtom(),s=a.type==="Character";if(lst(a)&&this.isRangeDash()){this.consumeChar("-");let l=this.classAtom(),h=l.type==="Character";if(lst(l)){if(l.value<a.value)throw Error("Range out of order in character class");r.push({from:a.value,to:l.value})}else d3e(a.value,r),r.push(Eo("-")),d3e(l.value,r)}else d3e(a.value,r)}return this.consumeChar("]"),{type:"Set",complement:t,value:r}}classAtom(){switch(this.peekChar()){case"]":case`
`:case"\r":case"\u2028":case"\u2029":throw Error("TBD");case"\\":return this.classEscape();default:return this.classPatternCharacterAtom()}}classEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"b":return this.consumeChar("b"),{type:"Character",value:Eo("\b")};case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}group(){let r=!0;this.consumeChar("("),this.peekChar(0)==="?"?(this.consumeChar("?"),this.consumeChar(":"),r=!1):this.groupIdx++;let t=this.disjunction();this.consumeChar(")");let a={type:"Group",capturing:r,value:t};return r&&(a.idx=this.groupIdx),a}positiveInteger(){let r=this.popChar();if(eri.test(r)===!1)throw Error("Expecting a positive integer");for(;Oke.test(this.peekChar(0));)r+=this.popChar();return parseInt(r,10)}integerIncludingZero(){let r=this.popChar();if(Oke.test(r)===!1)throw Error("Expecting an integer");for(;Oke.test(this.peekChar(0));)r+=this.popChar();return parseInt(r,10)}patternCharacter(){let r=this.popChar();switch(r){case`
`:case"\r":case"\u2028":case"\u2029":case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":throw Error("TBD");default:return{type:"Character",value:Eo(r)}}}isRegExpFlag(){switch(this.peekChar(0)){case"g":case"i":case"m":case"u":case"y":return!0;default:return!1}}isRangeDash(){return this.peekChar()==="-"&&this.isClassAtom(1)}isDigit(){return Oke.test(this.peekChar(0))}isClassAtom(r=0){switch(this.peekChar(r)){case"]":case`
`:case"\r":case"\u2028":case"\u2029":return!1;default:return!0}}isTerm(){return this.isAtom()||this.isAssertion()}isAtom(){if(this.isPatternCharacter())return!0;switch(this.peekChar(0)){case".":case"\\":case"[":case"(":return!0;default:return!1}}isAssertion(){switch(this.peekChar(0)){case"^":case"$":return!0;case"\\":switch(this.peekChar(1)){case"b":case"B":return!0;default:return!1}case"(":return this.peekChar(1)==="?"&&(this.peekChar(2)==="="||this.peekChar(2)==="!"||this.peekChar(2)==="<"&&(this.peekChar(3)==="="||this.peekChar(3)==="!"));default:return!1}}isQuantifier(){let r=this.saveState();try{return this.quantifier(!0)!==void 0}catch{return!1}finally{this.restoreState(r)}}isPatternCharacter(){switch(this.peekChar()){case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":case"/":case`
`:case"\r":case"\u2028":case"\u2029":return!1;default:return!0}}parseHexDigits(r){let t="";for(let s=0;s<r;s++){let l=this.popChar();if(Zti.test(l)===!1)throw Error("Expecting a HexDecimal digits");t+=l}return{type:"Character",value:parseInt(t,16)}}peekChar(r=0){return this.input[this.idx+r]}popChar(){let r=this.peekChar(0);return this.consumeChar(void 0),r}consumeChar(r){if(r!==void 0&&this.input[this.idx]!==r)throw Error("Expected: '"+r+"' but found: '"+this.input[this.idx]+"' at offset: "+this.idx);if(this.idx>=this.input.length)throw Error("Unexpected end of input");this.idx++}loc(r){return{begin:r,end:this.idx}}},s4e=class{static{i(this,"BaseRegExpVisitor")}static{J(this,"BaseRegExpVisitor")}visitChildren(r){for(let t in r){let a=r[t];r.hasOwnProperty(t)&&(a.type!==void 0?this.visit(a):Array.isArray(a)&&a.forEach(s=>{this.visit(s)},this))}}visit(r){switch(r.type){case"Pattern":this.visitPattern(r);break;case"Flags":this.visitFlags(r);break;case"Disjunction":this.visitDisjunction(r);break;case"Alternative":this.visitAlternative(r);break;case"StartAnchor":this.visitStartAnchor(r);break;case"EndAnchor":this.visitEndAnchor(r);break;case"WordBoundary":this.visitWordBoundary(r);break;case"NonWordBoundary":this.visitNonWordBoundary(r);break;case"Lookahead":this.visitLookahead(r);break;case"NegativeLookahead":this.visitNegativeLookahead(r);break;case"Lookbehind":this.visitLookbehind(r);break;case"NegativeLookbehind":this.visitNegativeLookbehind(r);break;case"Character":this.visitCharacter(r);break;case"Set":this.visitSet(r);break;case"Group":this.visitGroup(r);break;case"GroupBackReference":this.visitGroupBackReference(r);break;case"Quantifier":this.visitQuantifier(r);break}this.visitChildren(r)}visitPattern(r){}visitFlags(r){}visitDisjunction(r){}visitAlternative(r){}visitStartAnchor(r){}visitEndAnchor(r){}visitWordBoundary(r){}visitNonWordBoundary(r){}visitLookahead(r){}visitNegativeLookahead(r){}visitLookbehind(r){}visitNegativeLookbehind(r){}visitCharacter(r){}visitSet(r){}visitGroup(r){}visitGroupBackReference(r){}visitQuantifier(r){}},tri=/\r?\n/gm,rri=new mDr,nri=class extends s4e{static{i(this,"TerminalRegExpVisitor")}static{J(this,"TerminalRegExpVisitor")}constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join("")}reset(r){this.multiline=!1,this.regex=r,this.startRegexp="",this.isStarting=!0,this.endRegexpStack=[]}visitGroup(r){r.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(r){let t=String.fromCharCode(r.value);if(!this.multiline&&t===`
`&&(this.multiline=!0),r.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let a=Rae(t);this.endRegexpStack.push(a),this.isStarting&&(this.startRegexp+=a)}}visitSet(r){if(!this.multiline){let t=this.regex.substring(r.loc.begin,r.loc.end),a=new RegExp(t);this.multiline=!!`
`.match(a)}if(r.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let t=this.regex.substring(r.loc.begin,r.loc.end);this.endRegexpStack.push(t),this.isStarting&&(this.startRegexp+=t)}}visitChildren(r){r.type==="Group"&&r.quantifier||super.visitChildren(r)}},Iit=new nri;i(yDr,"isMultilineComment");J(yDr,"isMultilineComment");iri=`\f
\r \v \xA0\u1680\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF`.split("");i(Qot,"isWhitespace");J(Qot,"isWhitespace");i(Rae,"escapeRegExp");J(Rae,"escapeRegExp");i(bDr,"partialMatches");J(bDr,"partialMatches");i(vDr,"partialRegExp");J(vDr,"partialRegExp");i(wDr,"getEntryRule");J(wDr,"getEntryRule");i(xDr,"getHiddenRules");J(xDr,"getHiddenRules");i(Zot,"getAllReachableRules");J(Zot,"getAllReachableRules");i(elt,"ruleDfs");J(elt,"ruleDfs");i(TDr,"getCrossReferenceTerminal");J(TDr,"getCrossReferenceTerminal");i(kDr,"isCommentTerminal");J(kDr,"isCommentTerminal");i(CDr,"findNodesForProperty");J(CDr,"findNodesForProperty");i(tlt,"findNodeForProperty");J(tlt,"findNodeForProperty");i(o4e,"findNodesForPropertyInternal");J(o4e,"findNodesForPropertyInternal");i(EDr,"findNodeForKeyword");J(EDr,"findNodeForKeyword");i(SDr,"findNodesForKeywordInternal");J(SDr,"findNodesForKeywordInternal");i(ADr,"findAssignment");J(ADr,"findAssignment");i(rlt,"findNameAssignment");J(rlt,"findNameAssignment");i(nlt,"findNameAssignmentInternal");J(nlt,"findNameAssignmentInternal");i(ilt,"isDataTypeRule");J(ilt,"isDataTypeRule");i(alt,"isDataTypeRuleInternal");J(alt,"isDataTypeRuleInternal");i(slt,"getExplicitRuleType");J(slt,"getExplicitRuleType");i(JV,"getTypeName");J(JV,"getTypeName");i(RDr,"getActionType");J(RDr,"getActionType");i(LDr,"getRuleType");J(LDr,"getRuleType");i(l4e,"terminalRegex");J(l4e,"terminalRegex");olt=/[\s\S]/.source;i(iB,"abstractElementToRegex");J(iB,"abstractElementToRegex");i(_Dr,"terminalAlternativesToRegex");J(_Dr,"terminalAlternativesToRegex");i(DDr,"terminalGroupToRegex");J(DDr,"terminalGroupToRegex");i(IDr,"untilTokenToRegex");J(IDr,"untilTokenToRegex");i(MDr,"negateTokenToRegex");J(MDr,"negateTokenToRegex");i(NDr,"characterRangeToRegex");J(NDr,"characterRangeToRegex");i(p3e,"keywordToRegex");J(p3e,"keywordToRegex");i(WS,"withCardinality");J(WS,"withCardinality");i(ODr,"createGrammarConfig");J(ODr,"createGrammarConfig");i(z3e,"PRINT_ERROR");J(z3e,"PRINT_ERROR");i(llt,"PRINT_WARNING");J(llt,"PRINT_WARNING");i(clt,"timer");J(clt,"timer");i(ult,"toFastProperties");J(ult,"toFastProperties");i(PDr,"tokenLabel");J(PDr,"tokenLabel");i(BDr,"hasTokenLabel");J(BDr,"hasTokenLabel");XS=class{static{i(this,"AbstractProduction")}static{J(this,"AbstractProduction")}get definition(){return this._definition}set definition(r){this._definition=r}constructor(r){this._definition=r}accept(r){r.visit(this),this.definition.forEach(t=>{t.accept(r)})}},Bb=class extends XS{static{i(this,"NonTerminal")}static{J(this,"NonTerminal")}constructor(r){super([]),this.idx=1,Object.assign(this,eC(r))}set definition(r){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(r){r.visit(this)}},iW=class extends XS{static{i(this,"Rule")}static{J(this,"Rule")}constructor(r){super(r.definition),this.orgText="",Object.assign(this,eC(r))}},x2=class extends XS{static{i(this,"Alternative")}static{J(this,"Alternative")}constructor(r){super(r.definition),this.ignoreAmbiguities=!1,Object.assign(this,eC(r))}},b1=class extends XS{static{i(this,"Option")}static{J(this,"Option")}constructor(r){super(r.definition),this.idx=1,Object.assign(this,eC(r))}},ux=class extends XS{static{i(this,"RepetitionMandatory")}static{J(this,"RepetitionMandatory")}constructor(r){super(r.definition),this.idx=1,Object.assign(this,eC(r))}},hx=class extends XS{static{i(this,"RepetitionMandatoryWithSeparator")}static{J(this,"RepetitionMandatoryWithSeparator")}constructor(r){super(r.definition),this.idx=1,Object.assign(this,eC(r))}},kp=class extends XS{static{i(this,"Repetition")}static{J(this,"Repetition")}constructor(r){super(r.definition),this.idx=1,Object.assign(this,eC(r))}},T2=class extends XS{static{i(this,"RepetitionWithSeparator")}static{J(this,"RepetitionWithSeparator")}constructor(r){super(r.definition),this.idx=1,Object.assign(this,eC(r))}},k2=class extends XS{static{i(this,"Alternation")}static{J(this,"Alternation")}get definition(){return this._definition}set definition(r){this._definition=r}con… line truncated, 7.5 kB in all
`;i(XDr,"getOptimizedStartCodesIndices");J(XDr,"getOptimizedStartCodesIndices");i(V3e,"firstCharOptimizedIndices");J(V3e,"firstCharOptimizedIndices");i(Xie,"addOptimizedIdxToResult");J(Xie,"addOptimizedIdxToResult");i(KDr,"handleIgnoreCase");J(KDr,"handleIgnoreCase");i(ust,"findCode");J(ust,"findCode");i(W3e,"isWholeOptional");J(W3e,"isWholeOptional");ori=class extends s4e{static{i(this,"CharCodeFinder")}static{J(this,"CharCodeFinder")}constructor(r){super(),this.targetCharCodes=r,this.found=!1}visitChildren(r){if(this.found!==!0){switch(r.type){case"Lookahead":this.visitLookahead(r);return;case"NegativeLookahead":this.visitNegativeLookahead(r);return;case"Lookbehind":this.visitLookbehind(r);return;case"NegativeLookbehind":this.visitNegativeLookbehind(r);return}super.visitChildren(r)}}visitCharacter(r){this.targetCharCodes.includes(r.value)&&(this.found=!0)}visitSet(r){r.complement?ust(r,this.targetCharCodes)===void 0&&(this.found=!0):ust(r,this.targetCharCodes)!==void 0&&(this.found=!0)}};i(u4e,"canMatchCharCode");J(u4e,"canMatchCharCode");tB="PATTERN",Kie="defaultMode",Pke="modes",hst=0,m3e=1,fst=2,dst=3;i(JDr,"analyzeTokenTypes");J(JDr,"analyzeTokenTypes");i(QDr,"getAsciiClass");J(QDr,"getAsciiClass");i(ZDr,"validatePatterns");J(ZDr,"validatePatterns");i(e9r,"validateRegExpPattern");J(e9r,"validateRegExpPattern");i(t9r,"findMissingPatterns");J(t9r,"findMissingPatterns");i(r9r,"findInvalidPatterns");J(r9r,"findInvalidPatterns");lri=/[^\\][$]/;i(n9r,"findEndOfInputAnchor");J(n9r,"findEndOfInputAnchor");i(i9r,"findEmptyMatchRegExps");J(i9r,"findEmptyMatchRegExps");cri=/[^\\[][\^]|^\^/;i(a9r,"findStartOfInputAnchor");J(a9r,"findStartOfInputAnchor");i(s9r,"findUnsupportedFlags");J(s9r,"findUnsupportedFlags");i(o9r,"findDuplicatePatterns");J(o9r,"findDuplicatePatterns");i(l9r,"findInvalidGroupType");J(l9r,"findInvalidGroupType");i(c9r,"findModesThatDoNotExist");J(c9r,"findModesThatDoNotExist");i(u9r,"findUnreachablePatterns");J(u9r,"findUnreachablePatterns");i(h9r,"tryToMatchStrToPattern");J(h9r,"tryToMatchStrToPattern");i(f9r,"noMetaChar");J(f9r,"noMetaChar");i(d9r,"usesLookAheadOrBehind");J(d9r,"usesLookAheadOrBehind");i(pst,"addStickyFlag");J(pst,"addStickyFlag");i(p9r,"performRuntimeChecks");J(p9r,"performRuntimeChecks");i(g9r,"performWarningRuntimeChecks");J(g9r,"performWarningRuntimeChecks");i(hlt,"isCustomPattern");J(hlt,"isCustomPattern");i(m9r,"isShortPattern");J(m9r,"isShortPattern");uri={test:J(function(r){let t=r.length;for(let a=this.lastIndex;a<t;a++){let s=r.charCodeAt(a);if(s===10)return this.lastIndex=a+1,!0;if(s===13)return r.charCodeAt(a+1)===10?this.lastIndex=a+2:this.lastIndex=a+1,!0}return!1},"test"),lastIndex:0};i(flt,"checkLineBreaksIssues");J(flt,"checkLineBreaksIssues");i(y9r,"buildLineBreakIssueMessage");J(y9r,"buildLineBreakIssueMessage");i(dlt,"getCharCodes");J(dlt,"getCharCodes");i(y3e,"addToMapOfArrays");J(y3e,"addToMapOfArrays");Jie=256,b3e=[];i(u8,"charCodeToOptimizedIndex");J(u8,"charCodeToOptimizedIndex");i(b9r,"initCharCodeToOptimizedIndexMap");J(b9r,"initCharCodeToOptimizedIndexMap");i(lW,"tokenStructuredMatcher");J(lW,"tokenStructuredMatcher");i(fae,"tokenStructuredMatcherNoCategories");J(fae,"tokenStructuredMatcherNoCategories");vLr=1,v9r={};i(cW,"augmentTokenTypes");J(cW,"augmentTokenTypes");i(w9r,"expandCategories");J(w9r,"expandCategories");i(x9r,"assignTokenDefaultProps");J(x9r,"assignTokenDefaultProps");i(T9r,"assignCategoriesTokensProp");J(T9r,"assignCategoriesTokensProp");i(k9r,"assignCategoriesMapProp");J(k9r,"assignCategoriesMapProp");i(plt,"singleAssignCategoriesToksMap");J(plt,"singleAssignCategoriesToksMap");i(glt,"hasShortKeyProperty");J(glt,"hasShortKeyProperty");i(gst,"hasCategoriesProperty");J(gst,"hasCategoriesProperty");i(C9r,"hasExtendingTokensTypesProperty");J(C9r,"hasExtendingTokensTypesProperty");i(E9r,"hasExtendingTokensTypesMapProperty");J(E9r,"hasExtendingTokensTypesMapProperty");i(S9r,"isTokenType");J(S9r,"isTokenType");mst={buildUnableToPopLexerModeMessage(r){return`Unable to pop Lexer Mode after encountering Token ->${r.image}<- The Mode Stack is empty`},bui… line truncated, 5.4 kB in all
`,"\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:mst,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(Qie);w2=class{static{i(this,"Lexer")}static{J(this,"Lexer")}constructor(r,t=Qie){if(this.lexerDefinition=r,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.cachedGroupKeys=[],this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(s,l)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let h=new Array(this.traceInitIndent+1).join(" ");this.traceInitIndent<this.traceInitMaxIdent&&console.log(`${h}--> <${s}>`);let{time:f,value:d}=clt(l),m=f>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&m(`${h}<-- <${s}> time: ${f}ms`),this.traceInitIndent--,d}else return l()},typeof t=="boolean")throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object.
a boolean 2nd argument is no longer supported`);this.config=Object.assign({},Qie,t);let a=this.config.traceInitPerf;a===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof a=="number"&&(this.traceInitMaxIdent=a,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",()=>{let s,l=!0;this.TRACE_INIT("Lexer Config handling",()=>{if(this.config.lineTerminatorsPattern===Qie.lineTerminatorsPattern)this.config.lineTerminatorsPattern=uri;else if(this.config.lineTerminatorCharacters===Qie.lineTerminatorCharacters)throw Error(`Error: Missing <lineTerminatorCharacters> property on the Lexer config.
For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),Array.isArray(r)?s={modes:{defaultMode:[...r]},defaultMode:Kie}:(l=!1,s=Object.assign({},r))}),this.config.skipValidations===!1&&(this.TRACE_INIT("performRuntimeChecks",()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(p9r(s,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT("performWarningRuntimeChecks",()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(g9r(s,this.trackStartLines,this.config.lineTerminatorCharacters))})),s.modes=s.modes?s.modes:{},Object.entries(s.modes).forEach(([f,d])=>{s.modes[f]=d.filter(m=>m!==void 0)});let h=Object.keys(s.modes);if(Object.entries(s.modes).forEach(([f,d])=>{this.TRACE_INIT(`Mode: <${f}> processing`,()=>{if(this.modes.push(f),this.config.skipValidations===!1&&this.TRACE_INIT("validatePatterns",()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(ZDr(d,h))}),this.lexerDefinitionErrors.length===0){cW(d);let m;this.TRACE_INIT("analyzeTokenTypes",()=>{m=JDr(d,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[f]=m.patternIdxToConfig,this.charCodeToPatternIdxToConfig[f]=m.charCodeToPatternIdxToConfig,this.emptyGroups=Object.assign({},this.emptyGroups,m.emptyGroups),this.hasCustom=m.hasCustom||this.hasCustom,this.canModeBeOptimized[f]=m.canBeOptimized}})}),this.defaultMode=s.defaultMode,this.cachedGroupKeys=Object.keys(this.emptyGroups),this.lexerDefinitionErrors.length>0&&!this.config.deferDefinitionErrorsHandling){let d=this.lexerDefinitionErrors.map(m=>m.message).join(`-----------------------
`);throw new Error(`Errors detected in definition of Lexer:
This file is 5.3 MB, over the 1.0 MB the full view shows, so apm shows the lines around the cited one. Lines longer than 4 kB are cut.