tree-sitter-yaml/docs/assets/web-tree-sitter-0.15.9/tree-sitter.js

2 lines
54 KiB
JavaScript

var Module=void 0!==Module?Module:{};!function(e,t){"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?module.exports=t():window.TreeSitter=t()}(0,function(){var e,t={};for(e in Module)Module.hasOwnProperty(e)&&(t[e]=Module[e]);Module.arguments=[],Module.thisProgram="./this.program",Module.quit=function(e,t){throw t},Module.preRun=[],Module.postRun=[];var n,r=!1,o=!1,u=!1;r="object"==typeof window,o="function"==typeof importScripts,u="object"==typeof process&&"function"==typeof require&&!r&&!o,n=!r&&!u&&!o;var i,a,l="";u?(l=__dirname+"/",Module.read=function(e,t){var n;return i||(i=require("fs")),a||(a=require("path")),e=a.normalize(e),n=i.readFileSync(e),t?n:n.toString()},Module.readBinary=function(e){var t=Module.read(e,!0);return t.buffer||(t=new Uint8Array(t)),A(t.buffer),t},process.argv.length>1&&(Module.thisProgram=process.argv[1].replace(/\\/g,"/")),Module.arguments=process.argv.slice(2),"undefined"!=typeof module&&(module.exports=Module),process.on("uncaughtException",function(e){if(!(e instanceof lt))throw e}),process.on("unhandledRejection",_t),Module.quit=function(e){process.exit(e)},Module.inspect=function(){return"[Emscripten Module object]"}):n?("undefined"!=typeof read&&(Module.read=function(e){return read(e)}),Module.readBinary=function(e){var t;return"function"==typeof readbuffer?new Uint8Array(readbuffer(e)):(A("object"==typeof(t=read(e,"binary"))),t)},"undefined"!=typeof scriptArgs?Module.arguments=scriptArgs:void 0!==arguments&&(Module.arguments=arguments),"function"==typeof quit&&(Module.quit=function(e){quit(e)})):(r||o)&&(o?l=self.location.href:document.currentScript&&(l=document.currentScript.src),l=0!==l.indexOf("blob:")?l.substr(0,l.lastIndexOf("/")+1):"",Module.read=function(e){var t=new XMLHttpRequest;return t.open("GET",e,!1),t.send(null),t.responseText},o&&(Module.readBinary=function(e){var t=new XMLHttpRequest;return t.open("GET",e,!1),t.responseType="arraybuffer",t.send(null),new Uint8Array(t.response)}),Module.readAsync=function(e,t,n){var r=new XMLHttpRequest;r.open("GET",e,!0),r.responseType="arraybuffer",r.onload=function(){200==r.status||0==r.status&&r.response?t(r.response):n()},r.onerror=n,r.send(null)},Module.setWindowTitle=function(e){document.title=e});var s=Module.print||("undefined"!=typeof console?console.log.bind(console):"undefined"!=typeof print?print:null),d=Module.printErr||("undefined"!=typeof printErr?printErr:"undefined"!=typeof console&&console.warn.bind(console)||s);for(e in t)t.hasOwnProperty(e)&&(Module[e]=t[e]);t=void 0;var _=16;function c(e){var t=B[$>>2],n=t+e+15&-16;if(n<=be())B[$>>2]=n;else if(!ve(n))return 0;return t}function f(e,t){return t||(t=_),Math.ceil(e/t)*t}function m(e){switch(e){case"i1":case"i8":return 1;case"i16":return 2;case"i32":return 4;case"i64":return 8;case"float":return 4;case"double":return 8;default:if("*"===e[e.length-1])return 4;if("i"===e[0]){var t=parseInt(e.substr(1));return A(t%8==0,"getNativeTypeSize invalid bits "+t+", type "+e),t/8}return 0}}var p={"f64-rem":function(e,t){return e%t},debugger:function(){}},h={nextHandle:1,loadedLibs:{"-1":{refcount:1/0,name:"__self__",module:Module,global:!0}},loadedLibNames:{__self__:-1}};function y(e,t){t=t||{global:!0,nodelete:!0};var n,r=h.loadedLibNames[e];if(r)return n=h.loadedLibs[r],t.global&&!n.global&&(n.global=!0,"loading"!==n.module&&a(n.module)),t.nodelete&&n.refcount!==1/0&&(n.refcount=1/0),n.refcount++,t.loadAsync?Promise.resolve(r):r;function o(){if(t.fs){var n=t.fs.readFile(e,{encoding:"binary"});return n instanceof Uint8Array||(n=new Uint8Array(lib_data)),t.loadAsync?Promise.resolve(n):n}return t.loadAsync?(r=e,fetch(r,{credentials:"same-origin"}).then(function(e){if(!e.ok)throw"failed to load binary file at '"+r+"'";return e.arrayBuffer()}).then(function(e){return new Uint8Array(e)})):Module.readBinary(e);var r}function u(e){return g(e,t)}function i(){if(void 0!==Module.preloadedWasm&&void 0!==Module.preloadedWasm[e]){var n=Module.preloadedWasm[e];return t.loadAsync?Promise.resolve(n):n}return t.loadAsync?o().then(function(e){return u(e)}):u(o())}function a(e){for(var t in e)if(e.hasOwnProperty(t)){var n=t;"_"===t[0]&&(Module.hasOwnProperty(n)||(Module[n]=e[t]))}}function l(e){n.global&&a(e),n.module=e}return r=h.nextHandle++,n={refcount:t.nodelete?1/0:1,name:e,module:"loading",global:t.global},h.loadedLibNames[e]=r,h.loadedLibs[r]=n,t.loadAsync?i().then(function(e){return l(e),r}):(l(i()),r)}function g(e,t){A(1836278016==new Uint32Array(new Uint8Array(e.subarray(0,24)).buffer)[0],"need to see wasm magic number"),A(0===e[8],"need the dylink section to be first");var n=9;function r(){for(var t=0,r=1;;){var o=e[n++];if(t+=(127&o)*r,r*=128,!(128&o))break}return t}r();A(6===e[n]),A(e[++n]==="d".charCodeAt(0)),A(e[++n]==="y".charCodeAt(0)),A(e[++n]==="l".charCodeAt(0)),A(e[++n]==="i".charCodeAt(0)),A(e[++n]==="n".charCodeAt(0)),A(e[++n]==="k".charCodeAt(0)),n++;for(var o=r(),u=r(),i=r(),a=r(),l=r(),s=[],d=0;d<l;++d){var c=r(),m=e.subarray(n,n+c);n+=c;var h=D(m,0);s.push(h)}function g(){u=Math.pow(2,u),a=Math.pow(2,a),u=Math.max(u,_);for(var n=f(F(o+u),u),r=n;r<n+o;++r)q[r]=0;var l=Je,s=w,d=s.length,c=s;s.grow(i),A(s===c);for(r=n;r<n+o;r++)q[r]=0;for(r=d;r<d+i;r++)s.set(r,null);var m={},h=function(e,t){var n=Module[e];return n||(n=m[e]),n};for(var y in Module)y in l||(l[y]=Module[y]);var g={global:{NaN:NaN,Infinity:1/0},"global.Math":Math,env:new Proxy(l,{get:function(e,t){switch(t){case"__memory_base":case"gb":return n;case"__table_base":case"fb":return d}if(t in e)return e[t];if(t.startsWith("g$")){var r=t.substr(2);return e[t]=function(){return h(r)}}if(t.startsWith("fp$")){var o=t.split("$");A(3==o.length);r=o[1];var u=o[2],i=0;return e[t]=function(){if(!i){var e=h(r);i=function(e,t){var n=w,r=n.length;try{n.grow(1)}catch(e){if(!e instanceof RangeError)throw e;throw"Unable to grow wasm table. Use a higher value for RESERVED_FUNCTION_POINTERS or set ALLOW_TABLE_GROWTH."}try{n.set(r,e)}catch(u){if(!u instanceof TypeError)throw u;A(void 0!==t,"Missing signature argument to addFunction");var o=function(e,t){var n=[1,0,1,96],r=t.slice(0,1),o=t.slice(1),u={i:127,j:126,f:125,d:124};n.push(o.length);for(var i=0;i<o.length;++i)n.push(u[o[i]]);"v"==r?n.push(0):n=n.concat([1,u[r]]);n[1]=n.length-2;var a=new Uint8Array([0,97,115,109,1,0,0,0].concat(n,[2,7,1,1,101,1,102,0,0,7,5,1,1,102,0,0])),l=new WebAssembly.Module(a);return new WebAssembly.Instance(l,{e:{f:e}}).exports.f}(e,t);n.set(r,o)}return r}(e,u)}return i}}return t.startsWith("invoke_")?e[t]=invoke_X:e[t]=function(){return h(t).apply(null,arguments)}}}),asm2wasm:p};function M(e,t){var r={};for(var o in e.exports){var u=e.exports[o];"object"==typeof u&&(u=u.value),"number"==typeof u&&(u+=n),r[o]=u,t[o]=u}var i=r.__post_instantiate;return i&&(J?i():V.push(i)),r}return t.loadAsync?WebAssembly.instantiate(e,g).then(function(e){return M(e.instance,m)}):M(new WebAssembly.Instance(new WebAssembly.Module(e),g),m)}return t.loadAsync?Promise.all(s.map(function(e){return y(e,t)})).then(function(){return g()}):(s.forEach(function(e){y(e,t)}),g())}Module.loadWebAssemblyModule=g,Module.registerFunctions=function(e,t){e.forEach(function(e){Module["FUNCTION_TABLE_"+e]||(Module["FUNCTION_TABLE_"+e]=[])});var n=alignFunctionTables(),r=alignFunctionTables(t),o=n+r;e.forEach(function(e){var r=t["FUNCTION_TABLE_"+e],u=Module["FUNCTION_TABLE_"+e];A(r!==u),A(u.length===n);for(var i=0;i<r.length;i++)u.push(r[i]);A(u.length===o)}),A(o===alignFunctionTables())};var M,w,b=0,v=1024;function E(e,t,n){switch("*"===(t=t||"i8").charAt(t.length-1)&&(t="i32"),t){case"i1":case"i8":return q[e>>0];case"i16":return W[e>>1];case"i32":case"i64":return B[e>>2];case"float":return U[e>>2];case"double":return Y[e>>3];default:_t("invalid type for getValue: "+t)}return null}v=f(v,16),"object"!=typeof WebAssembly&&d("no native wasm support detected");var S=!1;function A(e,t){e||_t("Assertion failed: "+t)}function C(e,t,n,r){switch("*"===(n=n||"i8").charAt(n.length-1)&&(n="i32"),n){case"i1":case"i8":q[e>>0]=t;break;case"i16":W[e>>1]=t;break;case"i32":B[e>>2]=t;break;case"i64":tempI64=[t>>>0,(tempDouble=t,+te(tempDouble)>=1?tempDouble>0?(0|oe(+re(tempDouble/4294967296),4294967295))>>>0:~~+ne((tempDouble-+(~~tempDouble>>>0))/4294967296)>>>0:0)],B[e>>2]=tempI64[0],B[e+4>>2]=tempI64[1];break;case"float":U[e>>2]=t;break;case"double":Y[e>>3]=t;break;default:_t("invalid type for setValue: "+n)}}var I=3;function F(e){return J?tt(e):c(e)}var N="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function D(e,t,n){for(var r=t+n,o=t;e[o]&&!(o>=r);)++o;if(o-t>16&&e.subarray&&N)return N.decode(e.subarray(t,o));for(var u="";t<o;){var i=e[t++];if(128&i){var a=63&e[t++];if(192!=(224&i)){var l=63&e[t++];if((i=224==(240&i)?(15&i)<<12|a<<6|l:(7&i)<<18|a<<12|l<<6|63&e[t++])<65536)u+=String.fromCharCode(i);else{var s=i-65536;u+=String.fromCharCode(55296|s>>10,56320|1023&s)}}else u+=String.fromCharCode((31&i)<<6|a)}else u+=String.fromCharCode(i)}return u}function x(e,t){return e?D(O,e,t):""}function T(e,t,n,r){if(!(r>0))return 0;for(var o=n,u=n+r-1,i=0;i<e.length;++i){var a=e.charCodeAt(i);if(a>=55296&&a<=57343)a=65536+((1023&a)<<10)|1023&e.charCodeAt(++i);if(a<=127){if(n>=u)break;t[n++]=a}else if(a<=2047){if(n+1>=u)break;t[n++]=192|a>>6,t[n++]=128|63&a}else if(a<=65535){if(n+2>=u)break;t[n++]=224|a>>12,t[n++]=128|a>>6&63,t[n++]=128|63&a}else{if(n+3>=u)break;t[n++]=240|a>>18,t[n++]=128|a>>12&63,t[n++]=128|a>>6&63,t[n++]=128|63&a}}return t[n]=0,n-o}function R(e,t,n){return T(e,O,t,n)}function P(e){for(var t=0,n=0;n<e.length;++n){var r=e.charCodeAt(n);r>=55296&&r<=57343&&(r=65536+((1023&r)<<10)|1023&e.charCodeAt(++n)),r<=127?++t:t+=r<=2047?2:r<=65535?3:4}return t}"undefined"!=typeof TextDecoder&&new TextDecoder("utf-16le");function k(e){var t=P(e)+1,n=rt(t);return T(e,q,n,t),n}var L,q,O,W,B,U,Y;function Z(e,t){return e%t>0&&(e+=t-e%t),e}function j(){Module.HEAP8=q=new Int8Array(L),Module.HEAP16=W=new Int16Array(L),Module.HEAP32=B=new Int32Array(L),Module.HEAPU8=O=new Uint8Array(L),Module.HEAPU16=new Uint16Array(L),Module.HEAPU32=new Uint32Array(L),Module.HEAPF32=U=new Float32Array(L),Module.HEAPF64=Y=new Float64Array(L)}var $=27088,H=Module.TOTAL_MEMORY||33554432;function z(e){for(;e.length>0;){var t=e.shift();if("function"!=typeof t){var n=t.func;"number"==typeof n?void 0===t.arg?Module.dynCall_v(n):Module.dynCall_vi(n,t.arg):n(void 0===t.arg?null:t.arg)}else t()}}H<5242880&&d("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+H+"! (TOTAL_STACK=5242880)"),Module.buffer?L=Module.buffer:"object"==typeof WebAssembly&&"function"==typeof WebAssembly.Memory?(M=new WebAssembly.Memory({initial:H/65536}),L=M.buffer):L=new ArrayBuffer(H),j(),B[$>>2]=527e4;var K=[],V=[],G=[],X=[],J=!1;function Q(){J||(J=!0,z(V))}function ee(e){K.unshift(e)}var te=Math.abs,ne=Math.ceil,re=Math.floor,oe=Math.min,ue=0,ie=null,ae=null;function le(e){ue++,Module.monitorRunDependencies&&Module.monitorRunDependencies(ue)}function se(e){if(ue--,Module.monitorRunDependencies&&Module.monitorRunDependencies(ue),0==ue&&(null!==ie&&(clearInterval(ie),ie=null),ae)){var t=ae;ae=null,t()}}Module.preloadedImages={},Module.preloadedAudios={},Module.preloadedWasm={},ee(function(){if(Module.dynamicLibraries&&Module.dynamicLibraries.length>0&&!Module.readBinary)return le(),void Promise.all(Module.dynamicLibraries.map(function(e){return y(e,{loadAsync:!0,global:!0,nodelete:!0})})).then(function(){se()});var e;(e=Module.dynamicLibraries)&&e.forEach(function(e){y(e,{global:!0,nodelete:!0})})});var de="data:application/octet-stream;base64,";function _e(e){return String.prototype.startsWith?e.startsWith(de):0===e.indexOf(de)}var ce,fe="tree-sitter.wasm";function me(){try{if(Module.wasmBinary)return new Uint8Array(Module.wasmBinary);if(Module.readBinary)return Module.readBinary(fe);throw"both async and sync fetching of the wasm failed"}catch(e){_t(e)}}function pe(e){var t={env:e,global:{NaN:NaN,Infinity:1/0},"global.Math":Math,asm2wasm:p};function n(e,t){var n=e.exports;Module.asm=n,se()}if(le(),Module.instantiateWasm)try{return Module.instantiateWasm(t,n)}catch(e){return d("Module.instantiateWasm callback failed with error: "+e),!1}function u(e){n(e.instance)}function i(e){(Module.wasmBinary||!r&&!o||"function"!=typeof fetch?new Promise(function(e,t){e(me())}):fetch(fe,{credentials:"same-origin"}).then(function(e){if(!e.ok)throw"failed to load wasm binary file at '"+fe+"'";return e.arrayBuffer()}).catch(function(){return me()})).then(function(e){return WebAssembly.instantiate(e,t)}).then(e,function(e){d("failed to asynchronously prepare wasm: "+e),_t(e)})}return Module.wasmBinary||"function"!=typeof WebAssembly.instantiateStreaming||_e(fe)||"function"!=typeof fetch?i(u):WebAssembly.instantiateStreaming(fetch(fe,{credentials:"same-origin"}),t).then(u,function(e){d("wasm streaming compile failed: "+e),d("falling back to ArrayBuffer instantiation"),i(u)}),{}}_e(fe)||(ce=fe,fe=Module.locateFile?Module.locateFile(ce,l):l+ce),Module.asm=function(e,t,n){return t.memory=M,t.table=w=new WebAssembly.Table({initial:512,element:"anyfunc"}),t.__memory_base=1024,t.__table_base=0,pe(t)},V.push({func:function(){nt()}});function he(e){return Module.___errno_location&&(B[Module.___errno_location()>>2]=e),e}var ye={splitPath:function(e){return/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(e).slice(1)},normalizeArray:function(e,t){for(var n=0,r=e.length-1;r>=0;r--){var o=e[r];"."===o?e.splice(r,1):".."===o?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n;n--)e.unshift("..");return e},normalize:function(e){var t="/"===e.charAt(0),n="/"===e.substr(-1);return(e=ye.normalizeArray(e.split("/").filter(function(e){return!!e}),!t).join("/"))||t||(e="."),e&&n&&(e+="/"),(t?"/":"")+e},dirname:function(e){var t=ye.splitPath(e),n=t[0],r=t[1];return n||r?(r&&(r=r.substr(0,r.length-1)),n+r):"."},basename:function(e){if("/"===e)return"/";var t=e.lastIndexOf("/");return-1===t?e:e.substr(t+1)},extname:function(e){return ye.splitPath(e)[3]},join:function(){var e=Array.prototype.slice.call(arguments,0);return ye.normalize(e.join("/"))},join2:function(e,t){return ye.normalize(e+"/"+t)}},ge={DEFAULT_POLLMASK:5,mappings:{},umask:511,calculateAt:function(e,t){if("/"!==t[0]){var n;if(-100===e)n=FS.cwd();else{var r=FS.getStream(e);if(!r)throw new FS.ErrnoError(9);n=r.path}t=ye.join2(n,t)}return t},doStat:function(e,t,n){try{var r=e(t)}catch(e){if(e&&e.node&&ye.normalize(t)!==ye.normalize(FS.getPath(e.node)))return-20;throw e}return B[n>>2]=r.dev,B[n+4>>2]=0,B[n+8>>2]=r.ino,B[n+12>>2]=r.mode,B[n+16>>2]=r.nlink,B[n+20>>2]=r.uid,B[n+24>>2]=r.gid,B[n+28>>2]=r.rdev,B[n+32>>2]=0,tempI64=[r.size>>>0,(tempDouble=r.size,+te(tempDouble)>=1?tempDouble>0?(0|oe(+re(tempDouble/4294967296),4294967295))>>>0:~~+ne((tempDouble-+(~~tempDouble>>>0))/4294967296)>>>0:0)],B[n+40>>2]=tempI64[0],B[n+44>>2]=tempI64[1],B[n+48>>2]=4096,B[n+52>>2]=r.blocks,B[n+56>>2]=r.atime.getTime()/1e3|0,B[n+60>>2]=0,B[n+64>>2]=r.mtime.getTime()/1e3|0,B[n+68>>2]=0,B[n+72>>2]=r.ctime.getTime()/1e3|0,B[n+76>>2]=0,tempI64=[r.ino>>>0,(tempDouble=r.ino,+te(tempDouble)>=1?tempDouble>0?(0|oe(+re(tempDouble/4294967296),4294967295))>>>0:~~+ne((tempDouble-+(~~tempDouble>>>0))/4294967296)>>>0:0)],B[n+80>>2]=tempI64[0],B[n+84>>2]=tempI64[1],0},doMsync:function(e,t,n,r){var o=new Uint8Array(O.subarray(e,e+n));FS.msync(t,o,0,n,r)},doMkdir:function(e,t){return"/"===(e=ye.normalize(e))[e.length-1]&&(e=e.substr(0,e.length-1)),FS.mkdir(e,t,0),0},doMknod:function(e,t,n){switch(61440&t){case 32768:case 8192:case 24576:case 4096:case 49152:break;default:return-22}return FS.mknod(e,t,n),0},doReadlink:function(e,t,n){if(n<=0)return-22;var r=FS.readlink(e),o=Math.min(n,P(r)),u=q[t+o];return R(r,t,n+1),q[t+o]=u,o},doAccess:function(e,t){if(-8&t)return-22;var n;n=FS.lookupPath(e,{follow:!0}).node;var r="";return 4&t&&(r+="r"),2&t&&(r+="w"),1&t&&(r+="x"),r&&FS.nodePermissions(n,r)?-13:0},doDup:function(e,t,n){var r=FS.getStream(n);return r&&FS.close(r),FS.open(e,t,0,n,n).fd},doReadv:function(e,t,n,r){for(var o=0,u=0;u<n;u++){var i=B[t+8*u>>2],a=B[t+(8*u+4)>>2],l=FS.read(e,q,i,a,r);if(l<0)return-1;if(o+=l,l<a)break}return o},doWritev:function(e,t,n,r){for(var o=0,u=0;u<n;u++){var i=B[t+8*u>>2],a=B[t+(8*u+4)>>2],l=FS.write(e,q,i,a,r);if(l<0)return-1;o+=l}return o},varargs:0,get:function(e){return ge.varargs+=4,B[ge.varargs-4>>2]},getStr:function(){return x(ge.get())},getStreamFromFD:function(){var e=FS.getStream(ge.get());if(!e)throw new FS.ErrnoError(9);return e},get64:function(){var e=ge.get();ge.get();return e},getZero:function(){ge.get()}};function Me(){Module.abort()}function we(){_t()}function be(){return q.length}function ve(e){var t=be();if(e>2147418112)return!1;for(var n=Math.max(t,16777216);n<e;)n=n<=536870912?Z(2*n,65536):Math.min(Z((3*n+2147483648)/4,65536),2147418112);return!!function(e){e=Z(e,65536);var t=L.byteLength;try{return-1!==M.grow((e-t)/65536)&&(L=M.buffer,!0)}catch(e){return!1}}(n)&&(j(),!0)}Module._abort=Me;var Ee={};function Se(){var e=Se;return e.LLVM_SAVEDSTACKS||(e.LLVM_SAVEDSTACKS=[]),e.LLVM_SAVEDSTACKS.push(ut()),e.LLVM_SAVEDSTACKS.length-1}function Ae(e){return e%4==0&&(e%100!=0||e%400==0)}function Ce(e,t){for(var n=0,r=0;r<=t;n+=e[r++]);return n}var Ie=[31,29,31,30,31,30,31,31,30,31,30,31],Fe=[31,28,31,30,31,30,31,31,30,31,30,31];function Ne(e,t){for(var n=new Date(e.getTime());t>0;){var r=Ae(n.getFullYear()),o=n.getMonth(),u=(r?Ie:Fe)[o];if(!(t>u-n.getDate()))return n.setDate(n.getDate()+t),n;t-=u-n.getDate()+1,n.setDate(1),o<11?n.setMonth(o+1):(n.setMonth(0),n.setFullYear(n.getFullYear()+1))}return n}function De(e,t,n,r){var o=B[r+40>>2],u={tm_sec:B[r>>2],tm_min:B[r+4>>2],tm_hour:B[r+8>>2],tm_mday:B[r+12>>2],tm_mon:B[r+16>>2],tm_year:B[r+20>>2],tm_wday:B[r+24>>2],tm_yday:B[r+28>>2],tm_isdst:B[r+32>>2],tm_gmtoff:B[r+36>>2],tm_zone:o?x(o):""},i=x(n),a={"%c":"%a %b %d %H:%M:%S %Y","%D":"%m/%d/%y","%F":"%Y-%m-%d","%h":"%b","%r":"%I:%M:%S %p","%R":"%H:%M","%T":"%H:%M:%S","%x":"%m/%d/%y","%X":"%H:%M:%S"};for(var l in a)i=i.replace(new RegExp(l,"g"),a[l]);var s=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],d=["January","February","March","April","May","June","July","August","September","October","November","December"];function _(e,t,n){for(var r="number"==typeof e?e.toString():e||"";r.length<t;)r=n[0]+r;return r}function c(e,t){return _(e,t,"0")}function f(e,t){function n(e){return e<0?-1:e>0?1:0}var r;return 0===(r=n(e.getFullYear()-t.getFullYear()))&&0===(r=n(e.getMonth()-t.getMonth()))&&(r=n(e.getDate()-t.getDate())),r}function m(e){switch(e.getDay()){case 0:return new Date(e.getFullYear()-1,11,29);case 1:return e;case 2:return new Date(e.getFullYear(),0,3);case 3:return new Date(e.getFullYear(),0,2);case 4:return new Date(e.getFullYear(),0,1);case 5:return new Date(e.getFullYear()-1,11,31);case 6:return new Date(e.getFullYear()-1,11,30)}}function p(e){var t=Ne(new Date(e.tm_year+1900,0,1),e.tm_yday),n=new Date(t.getFullYear(),0,4),r=new Date(t.getFullYear()+1,0,4),o=m(n),u=m(r);return f(o,t)<=0?f(u,t)<=0?t.getFullYear()+1:t.getFullYear():t.getFullYear()-1}var h={"%a":function(e){return s[e.tm_wday].substring(0,3)},"%A":function(e){return s[e.tm_wday]},"%b":function(e){return d[e.tm_mon].substring(0,3)},"%B":function(e){return d[e.tm_mon]},"%C":function(e){return c((e.tm_year+1900)/100|0,2)},"%d":function(e){return c(e.tm_mday,2)},"%e":function(e){return _(e.tm_mday,2," ")},"%g":function(e){return p(e).toString().substring(2)},"%G":function(e){return p(e)},"%H":function(e){return c(e.tm_hour,2)},"%I":function(e){var t=e.tm_hour;return 0==t?t=12:t>12&&(t-=12),c(t,2)},"%j":function(e){return c(e.tm_mday+Ce(Ae(e.tm_year+1900)?Ie:Fe,e.tm_mon-1),3)},"%m":function(e){return c(e.tm_mon+1,2)},"%M":function(e){return c(e.tm_min,2)},"%n":function(){return"\n"},"%p":function(e){return e.tm_hour>=0&&e.tm_hour<12?"AM":"PM"},"%S":function(e){return c(e.tm_sec,2)},"%t":function(){return"\t"},"%u":function(e){return new Date(e.tm_year+1900,e.tm_mon+1,e.tm_mday,0,0,0,0).getDay()||7},"%U":function(e){var t=new Date(e.tm_year+1900,0,1),n=0===t.getDay()?t:Ne(t,7-t.getDay()),r=new Date(e.tm_year+1900,e.tm_mon,e.tm_mday);if(f(n,r)<0){var o=Ce(Ae(r.getFullYear())?Ie:Fe,r.getMonth()-1)-31,u=31-n.getDate()+o+r.getDate();return c(Math.ceil(u/7),2)}return 0===f(n,t)?"01":"00"},"%V":function(e){var t,n=new Date(e.tm_year+1900,0,4),r=new Date(e.tm_year+1901,0,4),o=m(n),u=m(r),i=Ne(new Date(e.tm_year+1900,0,1),e.tm_yday);return f(i,o)<0?"53":f(u,i)<=0?"01":(t=o.getFullYear()<e.tm_year+1900?e.tm_yday+32-o.getDate():e.tm_yday+1-o.getDate(),c(Math.ceil(t/7),2))},"%w":function(e){return new Date(e.tm_year+1900,e.tm_mon+1,e.tm_mday,0,0,0,0).getDay()},"%W":function(e){var t=new Date(e.tm_year,0,1),n=1===t.getDay()?t:Ne(t,0===t.getDay()?1:7-t.getDay()+1),r=new Date(e.tm_year+1900,e.tm_mon,e.tm_mday);if(f(n,r)<0){var o=Ce(Ae(r.getFullYear())?Ie:Fe,r.getMonth()-1)-31,u=31-n.getDate()+o+r.getDate();return c(Math.ceil(u/7),2)}return 0===f(n,t)?"01":"00"},"%y":function(e){return(e.tm_year+1900).toString().substring(2)},"%Y":function(e){return e.tm_year+1900},"%z":function(e){var t=e.tm_gmtoff,n=t>=0;return t=(t=Math.abs(t)/60)/60*100+t%60,(n?"+":"-")+String("0000"+t).slice(-4)},"%Z":function(e){return e.tm_zone},"%%":function(){return"%"}};for(var l in h)i.indexOf(l)>=0&&(i=i.replace(new RegExp(l,"g"),h[l](u)));var y,g,M=function(e,t,n){var r=n>0?n:P(e)+1,o=new Array(r),u=T(e,o,0,o.length);t&&(o.length=u);return o}(i,!1);return M.length>t?0:(y=M,g=e,q.set(y,g),M.length-1)}we=u?function(){var e=process.hrtime();return 1e3*e[0]+e[1]/1e6}:"undefined"!=typeof dateNow?dateNow:"object"==typeof performance&&performance&&"function"==typeof performance.now?function(){return performance.now()}:Date.now;var xe=v;function Te(e){return e|=0,mftCall_X(e)}function Re(e){return e|=0,0|mftCall_i(e)}function Pe(e,t){return e|=0,t|=0,0|mftCall_ii(e,0|t)}function ke(e,t,n,r,o,u,i){return e|=0,t|=0,n=+n,r|=0,o|=0,u|=0,i|=0,0|mftCall_iidiiii(e,0|t,+n,0|r,0|o,0|u,0|i)}function Le(e,t,n){return e|=0,t|=0,n|=0,0|mftCall_iii(e,0|t,0|n)}function qe(e,t,n,r){return e|=0,t|=0,n|=0,r|=0,0|mftCall_iiii(e,0|t,0|n,0|r)}function Oe(e,t,n,r,o){return e|=0,t|=0,n|=0,r|=0,o|=0,0|mftCall_iiiii(e,0|t,0|n,0|r,0|o)}function We(e,t,n,r,o,u){return e|=0,t|=0,n|=0,r|=0,o|=0,u=+u,0|mftCall_iiiiid(e,0|t,0|n,0|r,0|o,+u)}function Be(e,t,n,r,o,u){return e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,0|mftCall_iiiiii(e,0|t,0|n,0|r,0|o,0|u)}function Ue(e,t,n,r,o,u,i){return e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,i=+i,0|mftCall_iiiiiid(e,0|t,0|n,0|r,0|o,0|u,+i)}function Ye(e,t,n,r,o,u,i){return e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,i|=0,0|mftCall_iiiiiii(e,0|t,0|n,0|r,0|o,0|u,0|i)}function Ze(e,t,n,r,o,u,i,a){return e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,i|=0,a|=0,0|mftCall_iiiiiiii(e,0|t,0|n,0|r,0|o,0|u,0|i,0|a)}function je(e,t,n,r,o,u,i,a,l){return e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,i|=0,a|=0,l|=0,0|mftCall_iiiiiiiii(e,0|t,0|n,0|r,0|o,0|u,0|i,0|a,0|l)}function $e(e){e|=0,mftCall_v(e)}function He(e,t){e|=0,t|=0,mftCall_vi(e,0|t)}function ze(e,t,n){e|=0,t|=0,n|=0,mftCall_vii(e,0|t,0|n)}function Ke(e,t,n,r){e|=0,t|=0,n|=0,r|=0,mftCall_viii(e,0|t,0|n,0|r)}function Ve(e,t,n,r,o){e|=0,t|=0,n|=0,r|=0,o|=0,mftCall_viiii(e,0|t,0|n,0|r,0|o)}function Ge(e,t,n,r,o,u){e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,mftCall_viiiii(e,0|t,0|n,0|r,0|o,0|u)}function Xe(e,t,n,r,o,u,i){e|=0,t|=0,n|=0,r|=0,o|=0,u|=0,i|=0,mftCall_viiiiii(e,0|t,0|n,0|r,0|o,0|u,0|i)}var Je={H:_t,i:function(e){b=e},g:function(){return b},u:function(){throw S=!0,"Pure virtual function called!"},p:function(){},t:function(e,t){return he(1),-1},o:he,s:function(e,t){ge.varargs=t;try{var n=ge.getStreamFromFD(),r=ge.get(),o=ge.get(),u=ge.get(),i=ge.get();if(!(-1==r&&o<0||0==r&&o>=0))return-75;var a=o;return FS.llseek(n,a,i),tempI64=[n.position>>>0,(tempDouble=n.position,+te(tempDouble)>=1?tempDouble>0?(0|oe(+re(tempDouble/4294967296),4294967295))>>>0:~~+ne((tempDouble-+(~~tempDouble>>>0))/4294967296)>>>0:0)],B[u>>2]=tempI64[0],B[u+4>>2]=tempI64[1],n.getdents&&0===a&&0===i&&(n.getdents=null),0}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},r:function(e,t){ge.varargs=t;try{var n=ge.getStreamFromFD(),r=ge.get(),o=ge.get();return ge.doReadv(n,r,o)}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},n:function(e,t){ge.varargs=t;try{var n=ge.getStreamFromFD(),r=ge.get(),o=ge.get();return ge.doWritev(n,r,o)}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},G:function(e,t){ge.varargs=t;try{var n=ge.getStreamFromFD(),r=ge.get();switch(r){case 21509:case 21505:return n.tty?0:-25;case 21510:case 21511:case 21512:case 21506:case 21507:case 21508:return n.tty?0:-25;case 21519:if(!n.tty)return-25;var o=ge.get();return B[o>>2]=0,0;case 21520:return n.tty?-22:-25;case 21531:return o=ge.get(),FS.ioctl(n,r,o);case 21523:case 21524:return n.tty?0:-25;default:_t("bad ioctl syscall "+r)}}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},F:function(e,t){ge.varargs=t;try{var n=ge.getStreamFromFD();return FS.close(n),0}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},E:function(e,t){ge.varargs=t;try{var n=ge.get(),r=ge.get(),o=ge.mappings[n];if(!o)return 0;if(r===o.len){var u=FS.getStream(o.fd);ge.doMsync(n,u,r,o.flags),FS.munmap(u),ge.mappings[n]=null,o.allocated&&et(o.malloc)}return 0}catch(e){return"undefined"!=typeof FS&&e instanceof FS.ErrnoError||_t(e),-e.errno}},m:function(){},h:Me,q:function(e,t){var n;if(0===e)n=Date.now();else{if(1!==e||!(u||"undefined"!=typeof dateNow||"object"==typeof performance&&performance&&"function"==typeof performance.now))return he(22),-1;n=we()}return B[t>>2]=n/1e3|0,B[t+4>>2]=n%1e3*1e3*1e3|0,0},D:be,C:function(e,t,n){O.set(O.subarray(t,t+n),e)},B:ve,f:function(e){dt(e)},l:function e(t){return 0===t?0:(t=x(t),Ee.hasOwnProperty(t)?(e.ret&&et(e.ret),e.ret=(n=Ee[t],r=P(n)+1,(o=tt(r))&&T(n,q,o,r),o),e.ret):0);var n,r,o},k:function(e){var t=Se,n=t.LLVM_SAVEDSTACKS[e];t.LLVM_SAVEDSTACKS.splice(e,1),ot(n)},j:Se,A:function(){_t("trap!")},z:function(){return 0},y:function(e,t,n,r){return De(e,t,n,r)},x:function(e,t,n){if(It){const e=x(n);It(e,0!==t)}},w:function(e,t,n,r,o){var u=Ct(t,{row:n,column:r});"string"==typeof u?(C(o,u.length,"i32"),function(e,t,n){if(void 0===n&&(n=2147483647),n<2)return 0;for(var r=(n-=2)<2*e.length?n/2:e.length,o=0;o<r;++o){var u=e.charCodeAt(o);W[t>>1]=u,t+=2}W[t>>1]=0}(u,e,10240)):C(o,0,"i32")},v:function(e){_t("OOM")},a:27104,b:$,c:xe,d:0,e:27120},Qe=Module.asm({},Je,L);Module.asm=Qe;Module.__ZNKSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4copyEPcmm=function(){return Module.asm.I.apply(null,arguments)},Module.__ZNKSt3__220__vector_base_commonILb1EE20__throw_length_errorEv=function(){return Module.asm.J.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcm=function(){return Module.asm.K.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE7reserveEm=function(){return Module.asm.L.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE9__grow_byEmmmmmm=function(){return Module.asm.M.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE9push_backEc=function(){return Module.asm.N.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_=function(){return Module.asm.O.apply(null,arguments)},Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev=function(){return Module.asm.P.apply(null,arguments)},Module.__ZNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEE9push_backEw=function(){return Module.asm.Q.apply(null,arguments)},Module.__ZNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEED2Ev=function(){return Module.asm.R.apply(null,arguments)},Module.__ZdlPv=function(){return Module.asm.S.apply(null,arguments)},Module.__Znwm=function(){return Module.asm.T.apply(null,arguments)},Module._calloc=function(){return Module.asm.U.apply(null,arguments)};var et=Module._free=function(){return Module.asm.V.apply(null,arguments)},tt=(Module._iswalnum=function(){return Module.asm.W.apply(null,arguments)},Module._iswalpha=function(){return Module.asm.X.apply(null,arguments)},Module._iswdigit=function(){return Module.asm.Y.apply(null,arguments)},Module._iswlower=function(){return Module.asm.Z.apply(null,arguments)},Module._iswspace=function(){return Module.asm._.apply(null,arguments)},Module._malloc=function(){return Module.asm.$.apply(null,arguments)}),nt=(Module._memchr=function(){return Module.asm.aa.apply(null,arguments)},Module._memcmp=function(){return Module.asm.ba.apply(null,arguments)},Module._memcpy=function(){return Module.asm.ca.apply(null,arguments)},Module._strlen=function(){return Module.asm.da.apply(null,arguments)},Module._towupper=function(){return Module.asm.ea.apply(null,arguments)},Module._ts_init=function(){return Module.asm.fa.apply(null,arguments)},Module._ts_language_field_count=function(){return Module.asm.ga.apply(null,arguments)},Module._ts_language_field_name_for_id=function(){return Module.asm.ha.apply(null,arguments)},Module._ts_language_symbol_count=function(){return Module.asm.ia.apply(null,arguments)},Module._ts_language_symbol_name=function(){return Module.asm.ja.apply(null,arguments)},Module._ts_language_symbol_type=function(){return Module.asm.ka.apply(null,arguments)},Module._ts_language_version=function(){return Module.asm.la.apply(null,arguments)},Module._ts_node_child_by_field_id_wasm=function(){return Module.asm.ma.apply(null,arguments)},Module._ts_node_child_count_wasm=function(){return Module.asm.na.apply(null,arguments)},Module._ts_node_child_wasm=function(){return Module.asm.oa.apply(null,arguments)},Module._ts_node_children_wasm=function(){return Module.asm.pa.apply(null,arguments)},Module._ts_node_descendant_for_index_wasm=function(){return Module.asm.qa.apply(null,arguments)},Module._ts_node_descendant_for_position_wasm=function(){return Module.asm.ra.apply(null,arguments)},Module._ts_node_descendants_of_type_wasm=function(){return Module.asm.sa.apply(null,arguments)},Module._ts_node_end_index_wasm=function(){return Module.asm.ta.apply(null,arguments)},Module._ts_node_end_point_wasm=function(){return Module.asm.ua.apply(null,arguments)},Module._ts_node_has_changes_wasm=function(){return Module.asm.va.apply(null,arguments)},Module._ts_node_has_error_wasm=function(){return Module.asm.wa.apply(null,arguments)},Module._ts_node_is_missing_wasm=function(){return Module.asm.xa.apply(null,arguments)},Module._ts_node_is_named_wasm=function(){return Module.asm.ya.apply(null,arguments)},Module._ts_node_named_child_count_wasm=function(){return Module.asm.za.apply(null,arguments)},Module._ts_node_named_child_wasm=function(){return Module.asm.Aa.apply(null,arguments)},Module._ts_node_named_children_wasm=function(){return Module.asm.Ba.apply(null,arguments)},Module._ts_node_named_descendant_for_index_wasm=function(){return Module.asm.Ca.apply(null,arguments)},Module._ts_node_named_descendant_for_position_wasm=function(){return Module.asm.Da.apply(null,arguments)},Module._ts_node_next_named_sibling_wasm=function(){return Module.asm.Ea.apply(null,arguments)},Module._ts_node_next_sibling_wasm=function(){return Module.asm.Fa.apply(null,arguments)},Module._ts_node_parent_wasm=function(){return Module.asm.Ga.apply(null,arguments)},Module._ts_node_prev_named_sibling_wasm=function(){return Module.asm.Ha.apply(null,arguments)},Module._ts_node_prev_sibling_wasm=function(){return Module.asm.Ia.apply(null,arguments)},Module._ts_node_start_index_wasm=function(){return Module.asm.Ja.apply(null,arguments)},Module._ts_node_start_point_wasm=function(){return Module.asm.Ka.apply(null,arguments)},Module._ts_node_symbol_wasm=function(){return Module.asm.La.apply(null,arguments)},Module._ts_node_to_string_wasm=function(){return Module.asm.Ma.apply(null,arguments)},Module._ts_parser_delete=function(){return Module.asm.Na.apply(null,arguments)},Module._ts_parser_enable_logger_wasm=function(){return Module.asm.Oa.apply(null,arguments)},Module._ts_parser_new_wasm=function(){return Module.asm.Pa.apply(null,arguments)},Module._ts_parser_parse_wasm=function(){return Module.asm.Qa.apply(null,arguments)},Module._ts_parser_set_language=function(){return Module.asm.Ra.apply(null,arguments)},Module._ts_query_capture_count=function(){return Module.asm.Sa.apply(null,arguments)},Module._ts_query_capture_name_for_id=function(){return Module.asm.Ta.apply(null,arguments)},Module._ts_query_captures_wasm=function(){return Module.asm.Ua.apply(null,arguments)},Module._ts_query_delete=function(){return Module.asm.Va.apply(null,arguments)},Module._ts_query_matches_wasm=function(){return Module.asm.Wa.apply(null,arguments)},Module._ts_query_new=function(){return Module.asm.Xa.apply(null,arguments)},Module._ts_query_pattern_count=function(){return Module.asm.Ya.apply(null,arguments)},Module._ts_query_predicates_for_pattern=function(){return Module.asm.Za.apply(null,arguments)},Module._ts_query_string_count=function(){return Module.asm._a.apply(null,arguments)},Module._ts_query_string_value_for_id=function(){return Module.asm.$a.apply(null,arguments)},Module._ts_tree_cursor_current_field_id_wasm=function(){return Module.asm.ab.apply(null,arguments)},Module._ts_tree_cursor_current_node_id_wasm=function(){return Module.asm.bb.apply(null,arguments)},Module._ts_tree_cursor_current_node_is_missing_wasm=function(){return Module.asm.cb.apply(null,arguments)},Module._ts_tree_cursor_current_node_is_named_wasm=function(){return Module.asm.db.apply(null,arguments)},Module._ts_tree_cursor_current_node_type_id_wasm=function(){return Module.asm.eb.apply(null,arguments)},Module._ts_tree_cursor_current_node_wasm=function(){return Module.asm.fb.apply(null,arguments)},Module._ts_tree_cursor_delete_wasm=function(){return Module.asm.gb.apply(null,arguments)},Module._ts_tree_cursor_end_index_wasm=function(){return Module.asm.hb.apply(null,arguments)},Module._ts_tree_cursor_end_position_wasm=function(){return Module.asm.ib.apply(null,arguments)},Module._ts_tree_cursor_goto_first_child_wasm=function(){return Module.asm.jb.apply(null,arguments)},Module._ts_tree_cursor_goto_next_sibling_wasm=function(){return Module.asm.kb.apply(null,arguments)},Module._ts_tree_cursor_goto_parent_wasm=function(){return Module.asm.lb.apply(null,arguments)},Module._ts_tree_cursor_new_wasm=function(){return Module.asm.mb.apply(null,arguments)},Module._ts_tree_cursor_reset_wasm=function(){return Module.asm.nb.apply(null,arguments)},Module._ts_tree_cursor_start_index_wasm=function(){return Module.asm.ob.apply(null,arguments)},Module._ts_tree_cursor_start_position_wasm=function(){return Module.asm.pb.apply(null,arguments)},Module._ts_tree_delete=function(){return Module.asm.qb.apply(null,arguments)},Module._ts_tree_edit_wasm=function(){return Module.asm.rb.apply(null,arguments)},Module._ts_tree_get_changed_ranges_wasm=function(){return Module.asm.sb.apply(null,arguments)},Module._ts_tree_root_node_wasm=function(){return Module.asm.tb.apply(null,arguments)},Module.globalCtors=function(){return Module.asm.Ob.apply(null,arguments)}),rt=Module.stackAlloc=function(){return Module.asm.Pb.apply(null,arguments)},ot=Module.stackRestore=function(){return Module.asm.Qb.apply(null,arguments)},ut=Module.stackSave=function(){return Module.asm.Rb.apply(null,arguments)},Te=Module.dynCall_X=function(){return Module.asm.ub.apply(null,arguments)},Re=Module.dynCall_i=function(){return Module.asm.vb.apply(null,arguments)},Pe=Module.dynCall_ii=function(){return Module.asm.wb.apply(null,arguments)},ke=Module.dynCall_iidiiii=function(){return Module.asm.xb.apply(null,arguments)},Le=Module.dynCall_iii=function(){return Module.asm.yb.apply(null,arguments)},qe=Module.dynCall_iiii=function(){return Module.asm.zb.apply(null,arguments)},Oe=Module.dynCall_iiiii=function(){return Module.asm.Ab.apply(null,arguments)},We=Module.dynCall_iiiiid=function(){return Module.asm.Bb.apply(null,arguments)},Be=Module.dynCall_iiiiii=function(){return Module.asm.Cb.apply(null,arguments)},Ue=Module.dynCall_iiiiiid=function(){return Module.asm.Db.apply(null,arguments)},Ye=Module.dynCall_iiiiiii=function(){return Module.asm.Eb.apply(null,arguments)},Ze=Module.dynCall_iiiiiiii=function(){return Module.asm.Fb.apply(null,arguments)},je=Module.dynCall_iiiiiiiii=function(){return Module.asm.Gb.apply(null,arguments)},$e=Module.dynCall_v=function(){return Module.asm.Hb.apply(null,arguments)},He=Module.dynCall_vi=function(){return Module.asm.Ib.apply(null,arguments)},ze=Module.dynCall_vii=function(){return Module.asm.Jb.apply(null,arguments)},Ke=Module.dynCall_viii=function(){return Module.asm.Kb.apply(null,arguments)},Ve=Module.dynCall_viiii=function(){return Module.asm.Lb.apply(null,arguments)},Ge=Module.dynCall_viiiii=function(){return Module.asm.Mb.apply(null,arguments)},Xe=Module.dynCall_viiiiii=function(){return Module.asm.Nb.apply(null,arguments)};Module.dynCall_X=Te,Module.dynCall_i=Re,Module.dynCall_ii=Pe,Module.dynCall_iidiiii=ke,Module.dynCall_iii=Le,Module.dynCall_iiii=qe,Module.dynCall_iiiii=Oe,Module.dynCall_iiiiid=We,Module.dynCall_iiiiii=Be,Module.dynCall_iiiiiid=Ue,Module.dynCall_iiiiiii=Ye,Module.dynCall_iiiiiiii=Ze,Module.dynCall_iiiiiiiii=je,Module.dynCall_v=$e,Module.dynCall_vi=He,Module.dynCall_vii=ze,Module.dynCall_viii=Ke,Module.dynCall_viiii=Ve,Module.dynCall_viiiii=Ge,Module.dynCall_viiiiii=Xe;var it={_ZZNKSt3__27num_putIwNS_19ostreambuf_iteratorIwNS_11char_traitsIwEEEEE6do_putES4_RNS_8ios_baseEwPKvE5__fmt:17142,_ZZNKSt3__27num_putIwNS_19ostreambuf_iteratorIwNS_11char_traitsIwEEEEE6do_putES4_RNS_8ios_baseEwmE5__fmt:17153};for(var at in it)Module["_"+at]=xe+it[at];for(var at in Module.NAMED_GLOBALS=it,it)!function(e){var t=Module["_"+e];Module["g$_"+e]=function(){return t}}(at);function lt(e){this.name="ExitStatus",this.message="Program terminated with exit("+e+")",this.status=e}Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC1ERKS5_=Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_,Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED1Ev=Module.__ZNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev,Module.__ZNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEED1Ev=Module.__ZNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEED2Ev,Module.asm=Qe,Module.allocate=function(e,t,n,r){var o,u;"number"==typeof e?(o=!0,u=e):(o=!1,u=e.length);var i,a="string"==typeof t?t:null;if(i=n==I?r:[tt,rt,c][n](Math.max(u,a?1:t.length)),o){var l;for(r=i,A(0==(3&i)),l=i+(-4&u);r<l;r+=4)B[r>>2]=0;for(l=i+u;r<l;)q[r++>>0]=0;return i}if("i8"===a)return e.subarray||e.slice?O.set(e,i):O.set(new Uint8Array(e),i),i;for(var s,d,_,f=0;f<u;){var p=e[f];0!==(s=a||t[f])?("i64"==s&&(s="i32"),C(i+f,p,s),_!==s&&(d=m(s),_=s),f+=d):f++}return i},Module.getMemory=F,lt.prototype=new Error,lt.prototype.constructor=lt;function st(e){function t(){Module.calledRun||(Module.calledRun=!0,S||(Q(),z(G),Module.onRuntimeInitialized&&Module.onRuntimeInitialized(),Module._main&&ct&&Module.callMain(e),function(){if(Module.postRun)for("function"==typeof Module.postRun&&(Module.postRun=[Module.postRun]);Module.postRun.length;)e=Module.postRun.shift(),X.unshift(e);var e;z(X)}()))}e=e||Module.arguments,ue>0||(!function(){if(Module.preRun)for("function"==typeof Module.preRun&&(Module.preRun=[Module.preRun]);Module.preRun.length;)ee(Module.preRun.shift());z(K)}(),ue>0||Module.calledRun||(Module.setStatus?(Module.setStatus("Running..."),setTimeout(function(){setTimeout(function(){Module.setStatus("")},1),t()},1)):t()))}function dt(e,t){t&&Module.noExitRuntime&&0===e||(Module.noExitRuntime||(S=!0,e,!0,Module.onExit&&Module.onExit(e)),Module.quit(e,new lt(e)))}function _t(e){throw Module.onAbort&&Module.onAbort(e),void 0!==e?(s(e),d(e),e=JSON.stringify(e)):e="",S=!0,1,"abort("+e+"). Build with -s ASSERTIONS=1 for more info."}if(ae=function e(){Module.calledRun||st(),Module.calledRun||(ae=e)},Module.callMain=function(e){e=e||[],Q();var t=e.length+1,n=rt(4*(t+1));B[n>>2]=k(Module.thisProgram);for(var r=1;r<t;r++)B[(n>>2)+r]=k(e[r-1]);B[(n>>2)+t]=0;try{dt(Module._main(t,n,0),!0)}catch(e){if(e instanceof lt)return;if("SimulateInfiniteLoop"==e)return void(Module.noExitRuntime=!0);var o=e;e&&"object"==typeof e&&e.stack&&(o=[e,e.stack]),d("exception thrown: "+o),Module.quit(1,e)}finally{!0}},Module.run=st,Module.abort=_t,Module.preInit)for("function"==typeof Module.preInit&&(Module.preInit=[Module.preInit]);Module.preInit.length>0;)Module.preInit.pop()();var ct=!0;Module.noInitialRun&&(ct=!1),Module.noExitRuntime=!0,st();const ft=Module,mt={},pt=4,ht=5*pt,yt=2*pt,gt=2*pt+2*yt,Mt={row:0,column:0},wt=/[\w-.]*/g,bt=1,vt=2;var Et,St,At,Ct,It,Ft=new Promise(e=>{Module.onRuntimeInitialized=e}).then(()=>{At=ft._ts_init(),Et=E(At,"i32"),St=E(At+pt,"i32")});class Parser{static init(){return Ft}constructor(){if(null==At)throw new Error("You must first call Parser.init() and wait for it to resolve.");ft._ts_parser_new_wasm(),this[0]=E(At,"i32"),this[1]=E(At+pt,"i32")}delete(){ft._ts_parser_delete(this[0]),ft._free(this[1])}setLanguage(e){let t;if(e){if(e.constructor!==Language)throw new Error("Argument must be a Language");{t=e[0];const n=ft._ts_language_version(t);if(n<St||Et<n)throw new Error(`Incompatible language version ${n}. `+`Compatibility range ${St} through ${Et}.`)}}else t=0,e=null;return this.language=e,ft._ts_parser_set_language(this[0],t),this}getLanguage(){return this.language}parse(e,t,n){if("string"==typeof e)Ct=((t,n,r)=>e.slice(t,r));else{if("function"!=typeof e)throw new Error("Argument must be a string or a function");Ct=e}this.logCallback?(It=this.logCallback,ft._ts_parser_enable_logger_wasm(this[0],1)):(It=null,ft._ts_parser_enable_logger_wasm(this[0],0));let r=0,o=0;if(n&&n.includedRanges){r=n.includedRanges.length;let e=o=ft._calloc(r,gt);for(let t=0;t<r;t++)Wt(e,n.includedRanges[t]),e+=gt}const u=ft._ts_parser_parse_wasm(this[0],this[1],t?t[0]:0,o,r);if(!u)throw Ct=null,It=null,new Error("Parsing failed");const i=new Tree(mt,u,this.language,Ct);return Ct=null,It=null,i}reset(){ft._ts_parser_parse_wasm(this[0])}setTimeoutMicros(e){ft._ts_parser_set_timeout_micros(this[0],e)}getTimeoutMicros(e){ft._ts_parser_timeout_micros(this[0])}setLogger(e){if(e){if("function"!=typeof e)throw new Error("Logger callback must be a function")}else e=null;return this.logCallback=e,this}getLogger(){return this.logCallback}}class Tree{constructor(e,t,n,r){xt(e),this[0]=t,this.language=n,this.textCallback=r}copy(){const e=ft._ts_tree_copy(this[0]);return new Tree(mt,e,this.language,this.textCallback)}delete(){ft._ts_tree_delete(this[0])}edit(e){!function(e){let t=At;qt(t,e.startPosition),qt(t+=yt,e.oldEndPosition),qt(t+=yt,e.newEndPosition),C(t+=yt,e.startIndex,"i32"),C(t+=pt,e.oldEndIndex,"i32"),C(t+=pt,e.newEndIndex,"i32"),t+=pt}(e),ft._ts_tree_edit_wasm(this[0])}get rootNode(){return ft._ts_tree_root_node_wasm(this[0]),Pt(this)}getLanguage(){return this.language}walk(){return this.rootNode.walk()}getChangedRanges(e){if(e.constructor!==Tree)throw new TypeError("Argument must be a Tree");ft._ts_tree_get_changed_ranges_wasm(this[0],e[0]);const t=E(At,"i32"),n=E(At+pt,"i32"),r=new Array(t);if(t>0){let e=n;for(let n=0;n<t;n++)r[n]=Bt(e),e+=gt;ft._free(n)}return r}}class Node{constructor(e,t){xt(e),this.tree=t}get typeId(){return Rt(this),ft._ts_node_symbol_wasm(this.tree)}get type(){return this.tree.language.types[this.typeId]||"ERROR"}get endPosition(){return Rt(this),ft._ts_node_end_point_wasm(this.tree[0]),Ot(At)}get endIndex(){return Rt(this),ft._ts_node_end_index_wasm(this.tree[0])}get text(){let{startIndex:e,endIndex:t}=this;const n=t-e;let r=this.tree.textCallback(e,null,t);for(e+=r.length;e<t;){const n=this.tree.textCallback(e,null,t);if(!(n&&n.length>0))break;e+=n.length,r+=n}return e>t&&(r=r.slice(0,n)),r}isNamed(){return Rt(this),1===ft._ts_node_is_named_wasm(this.tree[0])}hasError(){return Rt(this),1===ft._ts_node_has_error_wasm(this.tree[0])}hasChanges(){return Rt(this),1===ft._ts_node_has_changes_wasm(this.tree[0])}isMissing(){return Rt(this),1===ft._ts_node_is_missing_wasm(this.tree[0])}equals(e){if(this===e)return!0;for(let t=0;t<5;t++)if(this[t]!==e[t])return!1;return!0}child(e){return Rt(this),ft._ts_node_child_wasm(this.tree[0],e),Pt(this.tree)}namedChild(e){return Rt(this),ft._ts_node_named_child_wasm(this.tree[0],e),Pt(this.tree)}childForFieldId(e){return Rt(this),ft._ts_node_child_by_field_id_wasm(this.tree[0],e),Pt(this.tree)}childForFieldName(e){const t=this.tree.language.fields.indexOf(e);if(-1!==t)return this.childForFieldId(t)}get childCount(){return Rt(this),ft._ts_node_child_count_wasm(this.tree[0])}get namedChildCount(){return Rt(this),ft._ts_node_named_child_count_wasm(this.tree[0])}get firstChild(){return this.child(0)}get firstNamedChild(){return this.namedChild(0)}get lastChild(){return this.child(this.childCount-1)}get lastNamedChild(){return this.namedChild(this.namedChildCount-1)}get children(){if(!this._children){Rt(this),ft._ts_node_children_wasm(this.tree[0]);const e=E(At,"i32"),t=E(At+pt,"i32");if(this._children=new Array(e),e>0){let n=t;for(let t=0;t<e;t++)this._children[t]=Pt(this.tree,n),n+=ht;ft._free(t)}}return this._children}get namedChildren(){if(!this._namedChildren){Rt(this),ft._ts_node_named_children_wasm(this.tree[0]);const e=E(At,"i32"),t=E(At+pt,"i32");if(this._namedChildren=new Array(e),e>0){let n=t;for(let t=0;t<e;t++)this._namedChildren[t]=Pt(this.tree,n),n+=ht;ft._free(t)}}return this._namedChildren}descendantsOfType(e,t,n){Array.isArray(e)||(e=[e]),t||(t=Mt),n||(n=Mt);const r=[],o=this.tree.language.types;for(let t=0,n=o.length;t<n;t++)e.includes(o[t])&&r.push(t);const u=ft._malloc(pt*r.count);for(let e=0,t=r.length;e<t;e++)C(u+e*pt,r[e],"i32");Rt(this),ft._ts_node_descendants_of_type_wasm(this.tree[0],u,r.length,t.row,t.column,n.row,n.column);const i=E(At,"i32"),a=E(At+pt,"i32"),l=new Array(i);if(i>0){let e=a;for(let t=0;t<i;t++)l[t]=Pt(this.tree,e),e+=ht}return ft._free(a),ft._free(u),l}get nextSibling(){return Rt(this),ft._ts_node_next_sibling_wasm(this.tree[0]),Pt(this.tree)}get previousSibling(){return Rt(this),ft._ts_node_prev_sibling_wasm(this.tree[0]),Pt(this.tree)}get nextNamedSibling(){return Rt(this),ft._ts_node_next_named_sibling_wasm(this.tree[0]),Pt(this.tree)}get previousNamedSibling(){return Rt(this),ft._ts_node_prev_named_sibling_wasm(this.tree[0]),Pt(this.tree)}get parent(){return Rt(this),ft._ts_node_parent_wasm(this.tree[0]),Pt(this.tree)}descendantForIndex(e,t=e){if("number"!=typeof e||"number"!=typeof t)throw new Error("Arguments must be numbers");Rt(this);let n=At+ht;return C(n,e,"i32"),C(n+pt,t,"i32"),ft._ts_node_descendant_for_index_wasm(this.tree[0]),Pt(this.tree)}namedDescendantForIndex(e,t=e){if("number"!=typeof e||"number"!=typeof t)throw new Error("Arguments must be numbers");Rt(this);let n=At+ht;return C(n,e,"i32"),C(n+pt,t,"i32"),ft._ts_node_named_descendant_for_index_wasm(this.tree[0]),Pt(this.tree)}descendantForPosition(e,t=e){if(!Tt(e)||!Tt(t))throw new Error("Arguments must be {row, column} objects");Rt(this);let n=At+ht;return qt(n,e),qt(n+yt,t),ft._ts_node_descendant_for_position_wasm(this.tree[0]),Pt(this.tree)}namedDescendantForPosition(e,t=e){if(!Tt(e)||!Tt(t))throw new Error("Arguments must be {row, column} objects");Rt(this);let n=At+ht;return qt(n,e),qt(n+yt,t),ft._ts_node_named_descendant_for_position_wasm(this.tree[0]),Pt(this.tree)}walk(){return Rt(this),ft._ts_tree_cursor_new_wasm(this.tree[0]),new TreeCursor(mt,this.tree)}toString(){Rt(this);const e=ft._ts_node_to_string_wasm(this.tree[0]),t=function(e){for(var t="";;){var n=O[e++>>0];if(!n)return t;t+=String.fromCharCode(n)}}(e);return ft._free(e),t}}class TreeCursor{constructor(e,t){xt(e),this.tree=t,Lt(this)}delete(){kt(this),ft._ts_tree_cursor_delete_wasm(this.tree[0])}reset(e){Rt(e),kt(this,At+ht),ft._ts_tree_cursor_reset_wasm(this.tree[0]),Lt(this)}get nodeType(){return this.tree.language.types[this.nodeTypeId]||"ERROR"}get nodeTypeId(){return kt(this),ft._ts_tree_cursor_current_node_type_id_wasm(this.tree[0])}get nodeId(){return kt(this),ft._ts_tree_cursor_current_node_id_wasm(this.tree[0])}get nodeIsNamed(){return kt(this),1===ft._ts_tree_cursor_current_node_is_named_wasm(this.tree[0])}get nodeIsMissing(){return kt(this),1===ft._ts_tree_cursor_current_node_is_missing_wasm(this.tree[0])}get startPosition(){return kt(this),ft._ts_tree_cursor_start_position_wasm(this.tree[0]),Ot(At)}get endPosition(){return kt(this),ft._ts_tree_cursor_end_position_wasm(this.tree[0]),Ot(At)}get startIndex(){return kt(this),ft._ts_tree_cursor_start_index_wasm(this.tree[0])}get endIndex(){return kt(this),ft._ts_tree_cursor_end_index_wasm(this.tree[0])}currentNode(){return kt(this),ft._ts_tree_cursor_current_node_wasm(this.tree[0]),Pt(this.tree)}currentFieldId(){return kt(this),ft._ts_tree_cursor_current_field_id_wasm(this.tree[0])}currentFieldName(){return this.tree.language.fields[this.currentFieldId()]}gotoFirstChild(){kt(this);const e=ft._ts_tree_cursor_goto_first_child_wasm(this.tree[0]);return Lt(this),1===e}gotoNextSibling(){kt(this);const e=ft._ts_tree_cursor_goto_next_sibling_wasm(this.tree[0]);return Lt(this),1===e}gotoParent(){kt(this);const e=ft._ts_tree_cursor_goto_parent_wasm(this.tree[0]);return Lt(this),1===e}}class Language{constructor(e,t){xt(e),this[0]=t,this.types=new Array(ft._ts_language_symbol_count(this[0]));for(let e=0,t=this.types.length;e<t;e++)ft._ts_language_symbol_type(this[0],e)<2&&(this.types[e]=x(ft._ts_language_symbol_name(this[0],e)));this.fields=new Array(ft._ts_language_field_count(this[0])+1);for(let e=0,t=this.fields.length;e<t;e++){const t=ft._ts_language_field_name_for_id(this[0],e);this.fields[e]=0!==t?x(t):null}}get version(){return ft._ts_language_version(this[0])}get fieldCount(){return this.fields.length-1}fieldIdForName(e){const t=this.fields.indexOf(e);return-1!==t?t:null}fieldNameForId(e){return this.fields[fieldName]||null}query(e){const t=P(e),n=ft._malloc(t+1);R(e,n,t+1);const r=ft._ts_query_new(this[0],n,t,At,At+pt);if(!r){const t=E(At+pt,"i32"),r=x(n,E(At,"i32")).length,o=e.substr(r,100),u=o.match(wt)[0];let i;switch(t){case 2:i=new RangeError(`Bad node name '${u}'`);break;case 3:i=new RangeError(`Bad field name '${u}'`);break;case 4:i=new RangeError(`Bad capture name @${u}`);break;default:i=new SyntaxError(`Bad syntax at offset ${r}: '${o}'...`)}throw i.index=r,i.length=u.length,ft._free(n),i}const o=ft._ts_query_string_count(r),u=ft._ts_query_capture_count(r),i=ft._ts_query_pattern_count(r),a=new Array(u),l=new Array(o);for(let e=0;e<u;e++){const t=ft._ts_query_capture_name_for_id(r,e,At),n=E(At,"i32");a[e]=x(t,n)}for(let e=0;e<o;e++){const t=ft._ts_query_string_value_for_id(r,e,At),n=E(At,"i32");l[e]=x(t,n)}const s=new Array(i);for(let e=0;e<i;e++){const t=ft._ts_query_predicates_for_pattern(r,e,At),n=E(At,"i32");s[e]=[];const o=[];let u=t;for(let t=0;t<n;t++){const t=E(u,"i32"),n=E(u+=pt,"i32");u+=pt,t===bt?o.push({type:"capture",name:a[n]}):t===vt?o.push({type:"string",value:l[n]}):o.length>0&&(s[e].push(Nt(o)),o.length=0)}}return ft._free(n),new Query(mt,r,a,s)}static load(e){let t;if("undefined"!=typeof process&&process.versions&&process.versions.node){const n=require("fs");t=Promise.resolve(n.readFileSync(e))}else t=fetch(e).then(e=>e.arrayBuffer().then(t=>{if(e.ok)return new Uint8Array(t);{const n=new TextDecoder("utf-8").decode(t);throw new Error(`Language.load failed with status ${e.status}.\n\n${n}`)}}));return t.then(e=>g(e,{loadAsync:!0})).then(e=>{const t=e[Object.keys(e).find(e=>e.includes("tree_sitter_"))]();return new Language(mt,t)})}}class Query{constructor(e,t,n,r){xt(e),this[0]=t,this.captureNames=n,this.predicates=r}delete(){ft._ts_query_delete(this[0])}matches(e,t,n){t||(t=Mt),n||(n=Mt),Rt(e),ft._ts_query_matches_wasm(this[0],e.tree[0],t.row,t.column,n.row,n.column);const r=E(At,"i32"),o=E(At+pt,"i32"),u=new Array(r);let i=o;for(let t=0;t<r;t++){const n=E(i,"i32"),r=E(i+=pt,"i32");i+=pt;const o=new Array(r);i=Dt(this,e.tree,i,o),this.predicates[n].every(e=>e(o))&&(u[t]={pattern:n,captures:o})}return ft._free(o),u}captures(e,t,n){t||(t=Mt),n||(n=Mt),Rt(e),ft._ts_query_captures_wasm(this[0],e.tree[0],t.row,t.column,n.row,n.column);const r=E(At,"i32"),o=E(At+pt,"i32"),u=[];let i=o;for(let t=0;t<r;t++){const t=E(i,"i32"),n=E(i+=pt,"i32"),r=E(i+=pt,"i32");i+=pt;const o=new Array(n);i=Dt(this,e.tree,i,o),this.predicates[t].every(e=>e(o))&&u.push(o[r])}return ft._free(o),u}}function Nt(e){if("string"!==e[0].type)throw new Error("Predicates must begin with a literal value");switch(e[0].value){case"eq?":if(3!==e.length)throw new Error(`Wrong number of arguments to \`eq?\` predicate. Expected 2, got ${e.length-1}`);if("capture"!==e[1].type)throw new Error(`First argument of \`eq?\` predicate must be a capture. Got "${e[1].value}"`);if("capture"===e[2].type){const t=e[1].name,n=e[2].name;return function(e){let r,o;for(const u of e)u.name===t&&(r=u.node),u.name===n&&(o=u.node);return r.text===o.text}}{const t=e[1].name,n=e[2].value;return function(e){for(const r of e)if(r.name===t)return r.node.text===n;return!1}}case"match?":if(3!==e.length)throw new Error(`Wrong number of arguments to \`match?\` predicate. Expected 2, got ${e.length-1}.`);if("capture"!==e[1].type)throw new Error(`First argument of \`match?\` predicate must be a capture. Got "${e[1].value}".`);if("string"!==e[2].type)throw new Error(`Second argument of \`match?\` predicate must be a string. Got @${e[2].value}.`);const t=e[1].name,n=new RegExp(e[2].value);return function(e){for(const r of e)if(r.name===t)return n.test(r.node.text);return!1};default:throw new Error(`Unknown query predicate \`${e[0].value}\``)}}function Dt(e,t,n,r){for(let o=0,u=r.length;o<u;o++){const u=E(n,"i32"),i=Pt(t,n+=pt);n+=ht,r[o]={name:e.captureNames[u],node:i}}return n}function xt(e){if(e!==mt)throw new Error("Illegal constructor")}function Tt(e){return e&&"number"==typeof e.row&&"number"==typeof e.column}function Rt(e){let t=At;C(t,e.id,"i32"),C(t+=pt,e.startIndex,"i32"),C(t+=pt,e.startPosition.row,"i32"),C(t+=pt,e.startPosition.column,"i32"),C(t+=pt,e[0],"i32")}function Pt(e,t=At){const n=E(t,"i32");if(0===n)return null;const r=E(t+=pt,"i32"),o=E(t+=pt,"i32"),u=E(t+=pt,"i32"),i=E(t+=pt,"i32"),a=new Node(mt,e);return a.id=n,a.startIndex=r,a.startPosition={row:o,column:u},a[0]=i,a}function kt(e,t=At){C(t+0*pt,e[0],"i32"),C(t+1*pt,e[1],"i32"),C(t+2*pt,e[2],"i32")}function Lt(e){e[0]=E(At+0*pt,"i32"),e[1]=E(At+1*pt,"i32"),e[2]=E(At+2*pt,"i32")}function qt(e,t){C(e,t.row,"i32"),C(e+pt,t.column,"i32")}function Ot(e){return{row:E(e,"i32"),column:E(e+pt,"i32")}}function Wt(e,t){qt(e,t.startPosition),qt(e+=yt,t.endPosition),C(e+=yt,t.startIndex,"i32"),C(e+=pt,t.endIndex,"i32"),e+=pt}function Bt(e){const t={};return t.startPosition=Ot(e),e+=yt,t.endPosition=Ot(e),e+=yt,t.startIndex=E(e,"i32"),e+=pt,t.endIndex=E(e,"i32"),t}return Parser.Language=Language,Parser});