mq-web 0.4.3 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core.cjs +2 -2
- package/dist/core.d.cts +1 -1
- package/dist/core.d.ts +1 -1
- package/dist/core.js +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.js +2 -2
- package/dist/mq_wasm.js +300 -177
- package/dist/mq_wasm_bg.wasm +0 -0
- package/package.json +1 -1
package/dist/core.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var
|
|
2
|
-
${t.stack}`:r}function et(t,e,n){let r,i;try{let l=o.__wbindgen_add_to_stack_pointer(-16),z=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),L=g,q=y(e,o.__wbindgen_export_0,o.__wbindgen_export_1),C=g;o.run(l,z,L,q,C,b(n));var _=a().getInt32(l+4*0,!0),s=a().getInt32(l+4*1,!0),f=a().getInt32(l+4*2,!0),u=a().getInt32(l+4*3,!0),d=_,m=s;if(u)throw d=0,m=0,w(f);return r=d,i=m,x(d,m)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(r,i,1)}}function nt(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.toAst(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function rt(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.format(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function it(t){let e=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),n=g,r=o.diagnostics(e,n);return w(r)}function ot(t){try{let i=o.__wbindgen_add_to_stack_pointer(-16),_=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;o.definedValues(i,_,s);var e=a().getInt32(i+4*0,!0),n=a().getInt32(i+4*1,!0),r=a().getInt32(i+4*2,!0);if(r)throw w(n);return w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}async function at(t,e){if(typeof Response=="function"&&t instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(t,e)}catch(r){if(t.ok&&ct.has(t.type)&&t.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let n=await t.arrayBuffer();return await WebAssembly.instantiate(n,e)}else{let n=await WebAssembly.instantiate(t,e);return n instanceof WebAssembly.Instance?{instance:n,module:t}:n}}function U(){let t={};return t.wbg={},t.wbg.__wbg_Error_e17e777aac105295=function(e,n){let r=Error(x(e,n));return b(r)},t.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,n){let r=String(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_entries_2be2f15bd5554996=function(e){let n=Object.entries(c(e));return b(n)},t.wbg.__wbg_get_0da715ceaecea5c8=function(e,n){let r=c(e)[n>>>0];return b(r)},t.wbg.__wbg_getwithrefkey_1dc361bd10053bfe=function(e,n){let r=c(e)[c(n)];return b(r)},t.wbg.__wbg_instanceof_ArrayBuffer_67f3012529f6a2dd=function(e){let n;try{n=c(e)instanceof ArrayBuffer}catch{n=!1}return n},t.wbg.__wbg_instanceof_Uint8Array_9a8378d955933db7=function(e){let n;try{n=c(e)instanceof Uint8Array}catch{n=!1}return n},t.wbg.__wbg_length_186546c51cd61acd=function(e){return c(e).length},t.wbg.__wbg_length_6bb7e81f9d7713e4=function(e){return c(e).length},t.wbg.__wbg_new_19c25a3f2fa63a02=function(){let e=new Object;return b(e)},t.wbg.__wbg_new_1f3a344cf3123716=function(){let e=new Array;return b(e)},t.wbg.__wbg_new_638ebfaedbf32a5e=function(e){let n=new Uint8Array(c(e));return b(n)},t.wbg.__wbg_prototypesetcall_3d4a26c1ed734349=function(e,n,r){Uint8Array.prototype.set.call(Z(e,n),c(r))},t.wbg.__wbg_set_3f1d0b984ed272ed=function(e,n,r){c(e)[w(n)]=w(r)},t.wbg.__wbg_set_90f6c0f7bd8c0415=function(e,n,r){c(e)[n>>>0]=w(r)},t.wbg.__wbg_wbindgenbooleanget_3fe6f642c7d97746=function(e){let n=c(e),r=typeof n=="boolean"?n:void 0;return E(r)?16777215:r?1:0},t.wbg.__wbg_wbindgendebugstring_99ef257a3ddda34d=function(e,n){let r=R(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_wbindgenin_d7a1ee10933d2d55=function(e,n){return c(e)in c(n)},t.wbg.__wbg_wbindgenisobject_307a53c6bd97fbf8=function(e){let n=c(e);return typeof n=="object"&&n!==null},t.wbg.__wbg_wbindgenisstring_d4fa939789f003b0=function(e){return typeof c(e)=="string"},t.wbg.__wbg_wbindgenisundefined_c4b71d073b92f3c5=function(e){return c(e)===void 0},t.wbg.__wbg_wbindgenjsvallooseeq_9bec8c9be826bed1=function(e,n){return c(e)==c(n)},t.wbg.__wbg_wbindgennumberget_f74b4c7525ac05cb=function(e,n){let r=c(n),i=typeof r=="number"?r:void 0;a().setFloat64(e+8*1,E(i)?0:i,!0),a().setInt32(e+4*0,!E(i),!0)},t.wbg.__wbg_wbindgenstringget_0f16a6ddddef376f=function(e,n){let r=c(n),i=typeof r=="string"?r:void 0;var _=E(i)?0:y(i,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;a().setInt32(e+4*1,s,!0),a().setInt32(e+4*0,_,!0)},t.wbg.__wbg_wbindgenthrow_451ec1a8469d7eb6=function(e,n){throw new Error(x(e,n))},t.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,n){let r=x(e,n);return b(r)},t.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return b(e)},t.wbg.__wbindgen_object_clone_ref=function(e){let n=c(e);return b(n)},t.wbg.__wbindgen_object_drop_ref=function(e){w(e)},t}function P(t,e){return o=t.exports,$.__wbindgen_wasm_module=e,h=null,A=null,o}function _t(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module:t}=t:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=U();t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));let n=new WebAssembly.Instance(t,e);return P(n,t)}async function $(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module_or_path:t}=t:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof t>"u"&&(t=new URL("mq_wasm_bg.wasm",ft.url));let e=U();(typeof t=="string"||typeof Request=="function"&&t instanceof Request||typeof URL=="function"&&t instanceof URL)&&(t=fetch(t));let{instance:n,module:r}=await at(await t,e);return P(n,r)}var ft,o,A,F,K,D,p,S,g,O,h,st,j,ct,v,V=H(()=>{"use strict";ft={},A=null;F=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});F.decode();K=2146435072,D=0;p=new Array(128).fill(void 0);p.push(void 0,null,!0,!1);S=p.length;g=0,O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(t,e){let n=O.encode(t);return e.set(n),{read:t.length,written:n.length}});h=null;st=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(t=>o.__wbg_runoptions_free(t>>>0,1)),j=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,st.unregister(this),e}free(){let e=this.__destroy_into_raw();o.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(j.prototype[Symbol.dispose]=j.prototype.free);ct=new Set(["basic","cors","default"]);v=$});var lt={};T(lt,{definedValues:()=>wt,diagnostics:()=>gt,format:()=>bt,run:()=>ut,toAst:()=>dt});module.exports=G(lt);V();var k=null;async function W(){return k||(await(async()=>{try{await v();let t=await Promise.resolve().then(()=>(V(),B));k={run:t.run,toAst:t.toAst,format:t.format,diagnostics:t.diagnostics,definedValues:t.definedValues}}catch(t){throw new Error(`Failed to initialize mq WebAssembly module: ${t}`)}})(),k)}async function ut(t,e,n={}){return await(await W()).run(t,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...n})}async function dt(t){return await(await W()).toAst(t)}async function bt(t){return await(await W()).format(t)}async function gt(t){return await(await W()).diagnostics(t)}async function wt(t){return await(await W()).definedValues(t)}0&&(module.exports={definedValues,diagnostics,format,run,toAst});
|
|
1
|
+
"use strict";var D=Object.defineProperty;var z=Object.getOwnPropertyDescriptor;var q=Object.getOwnPropertyNames;var $=Object.prototype.hasOwnProperty;var C=(n,e)=>()=>(n&&(e=n(n=0)),e);var T=(n,e)=>{for(var t in e)D(n,t,{get:e[t],enumerable:!0})},H=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of q(e))!$.call(n,i)&&i!==t&&D(n,i,{get:()=>e[i],enumerable:!(r=z(e,i))||r.enumerable});return n};var N=n=>H(D({},"__esModule",{value:!0}),n);var B={};T(B,{RunOptions:()=>S,default:()=>P,definedValues:()=>en,diagnostics:()=>nn,format:()=>Z,initSync:()=>_n,run:()=>K,toAst:()=>Q});function h(){return(m===null||m.byteLength===0)&&(m=new Uint8Array(c.memory.buffer)),m}function G(n,e){return E+=e,E>=v&&(W=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),W.decode(),E=e),W.decode(h().subarray(n,n+e))}function O(n,e){return n=n>>>0,G(n,e)}function s(n){x===w.length&&w.push(w.length+1);let e=x;return x=w[e],w[e]=n,e}function o(n){return w[n]}function b(n,e,t){if(t===void 0){let f=A.encode(n),l=e(f.length,1)>>>0;return h().subarray(l,l+f.length).set(f),u=f.length,l}let r=n.length,i=e(r,1)>>>0,a=h(),_=0;for(;_<r;_++){let f=n.charCodeAt(_);if(f>127)break;a[i+_]=f}if(_!==r){_!==0&&(n=n.slice(_)),i=t(i,r,r=_+n.length*3,1)>>>0;let f=h().subarray(i+_,i+r),l=A.encodeInto(n,f);_+=l.written,i=t(i,r,_,1)>>>0}return u=_,i}function y(){return(p===null||p.buffer.detached===!0||p.buffer.detached===void 0&&p.buffer!==c.memory.buffer)&&(p=new DataView(c.memory.buffer)),p}function g(n){return n==null}function R(n){let e=typeof n;if(e=="number"||e=="boolean"||n==null)return`${n}`;if(e=="string")return`"${n}"`;if(e=="symbol"){let i=n.description;return i==null?"Symbol":`Symbol(${i})`}if(e=="function"){let i=n.name;return typeof i=="string"&&i.length>0?`Function(${i})`:"Function"}if(Array.isArray(n)){let i=n.length,a="[";i>0&&(a+=R(n[0]));for(let _=1;_<i;_++)a+=", "+R(n[_]);return a+="]",a}let t=/\[object ([^\]]+)\]/.exec(toString.call(n)),r;if(t&&t.length>1)r=t[1];else return toString.call(n);if(r=="Object")try{return"Object("+JSON.stringify(n)+")"}catch{return"Object"}return n instanceof Error?`${n.name}: ${n.message}
|
|
2
|
+
${n.stack}`:r}function M(n,e){try{return n.apply(this,e)}catch(t){c.__wbindgen_export3(s(t))}}function X(n,e){return n=n>>>0,h().subarray(n/1,n/1+e)}function Y(n){n<132||(w[n]=x,x=n)}function d(n){let e=o(n);return Y(n),e}function J(n,e,t,r){let i={a:n,b:e,cnt:1,dtor:t},a=(..._)=>{i.cnt++;let f=i.a;i.a=0;try{return r(f,i.b,..._)}finally{i.a=f,a._wbg_cb_unref()}};return a._wbg_cb_unref=()=>{--i.cnt===0&&(i.dtor(i.a,i.b),i.a=0,k.unregister(i))},k.register(a,i,i),a}function K(n,e,t){let r=b(n,c.__wbindgen_export,c.__wbindgen_export2),i=u,a=b(e,c.__wbindgen_export,c.__wbindgen_export2),_=u,f=c.run(r,i,a,_,s(t));return d(f)}function Q(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.toAst(e,t);return d(r)}function Z(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.format(e,t);return d(r)}function nn(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.diagnostics(e,t);return d(r)}function en(n,e){let t=b(n,c.__wbindgen_export,c.__wbindgen_export2),r=u;var i=g(e)?0:b(e,c.__wbindgen_export,c.__wbindgen_export2),a=u;let _=c.definedValues(t,r,i,a);return d(_)}function tn(n,e,t){c.__wasm_bindgen_func_elem_2761(n,e,s(t))}function rn(n,e,t,r){c.__wasm_bindgen_func_elem_712(n,e,s(t),s(r))}async function sn(n,e){if(typeof Response=="function"&&n instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(n,e)}catch(r){if(n.ok&&cn.has(n.type)&&n.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let t=await n.arrayBuffer();return await WebAssembly.instantiate(t,e)}else{let t=await WebAssembly.instantiate(n,e);return t instanceof WebAssembly.Instance?{instance:t,module:n}:t}}function U(){let n={};return n.wbg={},n.wbg.__wbg_Error_e83987f665cf5504=function(e,t){let r=Error(O(e,t));return s(r)},n.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,t){let r=String(o(t)),i=b(r,c.__wbindgen_export,c.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_boolean_get_6d5a1ee65bab5f68=function(e){let t=o(e),r=typeof t=="boolean"?t:void 0;return g(r)?16777215:r?1:0},n.wbg.__wbg___wbindgen_debug_string_df47ffb5e35e6763=function(e,t){let r=R(o(t)),i=b(r,c.__wbindgen_export,c.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_in_bb933bd9e1b3bc0f=function(e,t){return o(e)in o(t)},n.wbg.__wbg___wbindgen_is_function_ee8a6c5833c90377=function(e){return typeof o(e)=="function"},n.wbg.__wbg___wbindgen_is_object_c818261d21f283a4=function(e){let t=o(e);return typeof t=="object"&&t!==null},n.wbg.__wbg___wbindgen_is_string_fbb76cb2940daafd=function(e){return typeof o(e)=="string"},n.wbg.__wbg___wbindgen_is_undefined_2d472862bd29a478=function(e){return o(e)===void 0},n.wbg.__wbg___wbindgen_jsval_loose_eq_b664b38a2f582147=function(e,t){return o(e)==o(t)},n.wbg.__wbg___wbindgen_number_get_a20bf9b85341449d=function(e,t){let r=o(t),i=typeof r=="number"?r:void 0;y().setFloat64(e+8*1,g(i)?0:i,!0),y().setInt32(e+4*0,!g(i),!0)},n.wbg.__wbg___wbindgen_string_get_e4f06c90489ad01b=function(e,t){let r=o(t),i=typeof r=="string"?r:void 0;var a=g(i)?0:b(i,c.__wbindgen_export,c.__wbindgen_export2),_=u;y().setInt32(e+4*1,_,!0),y().setInt32(e+4*0,a,!0)},n.wbg.__wbg___wbindgen_throw_b855445ff6a94295=function(e,t){throw new Error(O(e,t))},n.wbg.__wbg__wbg_cb_unref_2454a539ea5790d9=function(e){o(e)._wbg_cb_unref()},n.wbg.__wbg_arrayBuffer_5930938a049abc90=function(e){let t=o(e).arrayBuffer();return s(t)},n.wbg.__wbg_call_525440f72fbfc0ea=function(){return M(function(e,t,r){let i=o(e).call(o(t),o(r));return s(i)},arguments)},n.wbg.__wbg_call_e762c39fa8ea36bf=function(){return M(function(e,t){let r=o(e).call(o(t));return s(r)},arguments)},n.wbg.__wbg_done_2042aa2670fb1db1=function(e){return o(e).done},n.wbg.__wbg_entries_a1e792d46512c8bf=function(e){let t=o(e).entries();return s(t)},n.wbg.__wbg_entries_e171b586f8f6bdbf=function(e){let t=Object.entries(o(e));return s(t)},n.wbg.__wbg_from_a4ad7cbddd0d7135=function(e){let t=Array.from(o(e));return s(t)},n.wbg.__wbg_getDirectory_7e7a55f640412401=function(e){let t=o(e).getDirectory();return s(t)},n.wbg.__wbg_getFile_985459d958bb9dfe=function(e){let t=o(e).getFile();return s(t)},n.wbg.__wbg_get_7bed016f185add81=function(e,t){let r=o(e)[t>>>0];return s(r)},n.wbg.__wbg_get_with_ref_key_1dc361bd10053bfe=function(e,t){let r=o(e)[o(t)];return s(r)},n.wbg.__wbg_instanceof_ArrayBuffer_70beb1189ca63b38=function(e){let t;try{t=o(e)instanceof ArrayBuffer}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemDirectoryHandle_7a17cc3353820fcf=function(e){let t;try{t=o(e)instanceof FileSystemDirectoryHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemFileHandle_5730ec1d120983f4=function(e){let t;try{t=o(e)instanceof FileSystemFileHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_Uint8Array_20c8e73002f7af98=function(e){let t;try{t=o(e)instanceof Uint8Array}catch{t=!1}return t},n.wbg.__wbg_instanceof_Window_4846dbb3de56c84c=function(e){let t;try{t=o(e)instanceof Window}catch{t=!1}return t},n.wbg.__wbg_length_69bca3cb64fc8748=function(e){return o(e).length},n.wbg.__wbg_length_cdd215e10d9dd507=function(e){return o(e).length},n.wbg.__wbg_navigator_971384882e8ea23a=function(e){let t=o(e).navigator;return s(t)},n.wbg.__wbg_new_1acc0b6eea89d040=function(){let e=new Object;return s(e)},n.wbg.__wbg_new_3c3d849046688a66=function(e,t){try{var r={a:e,b:t},i=(_,f)=>{let l=r.a;r.a=0;try{return rn(l,r.b,_,f)}finally{r.a=l}};let a=new Promise(i);return s(a)}finally{r.a=r.b=0}},n.wbg.__wbg_new_5a79be3ab53b8aa5=function(e){let t=new Uint8Array(o(e));return s(t)},n.wbg.__wbg_new_e17d9f43105b08be=function(){let e=new Array;return s(e)},n.wbg.__wbg_new_no_args_ee98eee5275000a4=function(e,t){let r=new Function(O(e,t));return s(r)},n.wbg.__wbg_next_eedaffcadc567b75=function(){return M(function(e){let t=o(e).next();return s(t)},arguments)},n.wbg.__wbg_prototypesetcall_2a6620b6922694b2=function(e,t,r){Uint8Array.prototype.set.call(X(e,t),o(r))},n.wbg.__wbg_queueMicrotask_34d692c25c47d05b=function(e){let t=o(e).queueMicrotask;return s(t)},n.wbg.__wbg_queueMicrotask_9d76cacb20c84d58=function(e){queueMicrotask(o(e))},n.wbg.__wbg_resolve_caf97c30b83f7053=function(e){let t=Promise.resolve(o(e));return s(t)},n.wbg.__wbg_set_3f1d0b984ed272ed=function(e,t,r){o(e)[d(t)]=d(r)},n.wbg.__wbg_set_c213c871859d6500=function(e,t,r){o(e)[t>>>0]=d(r)},n.wbg.__wbg_size_0a5a003dbf5dfee8=function(e){return o(e).size},n.wbg.__wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e=function(){let e=typeof global>"u"?null:global;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac=function(){let e=typeof globalThis>"u"?null:globalThis;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_SELF_6fdf4b64710cc91b=function(){let e=typeof self>"u"?null:self;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2=function(){let e=typeof window>"u"?null:window;return g(e)?0:s(e)},n.wbg.__wbg_storage_3e7b84b6fbb9dd1c=function(e){let t=o(e).storage;return s(t)},n.wbg.__wbg_then_4f46f6544e6b4a28=function(e,t){let r=o(e).then(o(t));return s(r)},n.wbg.__wbg_then_70d05cf780a18d77=function(e,t,r){let i=o(e).then(o(t),o(r));return s(i)},n.wbg.__wbg_value_692627309814bb8c=function(e){let t=o(e).value;return s(t)},n.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,t){let r=O(e,t);return s(r)},n.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return s(e)},n.wbg.__wbindgen_cast_fd0586cfe4f12dd7=function(e,t){let r=J(e,t,c.__wasm_bindgen_func_elem_2760,tn);return s(r)},n.wbg.__wbindgen_object_clone_ref=function(e){let t=o(e);return s(t)},n.wbg.__wbindgen_object_drop_ref=function(e){d(e)},n}function V(n,e){return c=n.exports,L.__wbindgen_wasm_module=e,p=null,m=null,c}function _n(n){if(c!==void 0)return c;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module:n}=n:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=U();n instanceof WebAssembly.Module||(n=new WebAssembly.Module(n));let t=new WebAssembly.Instance(n,e);return V(t,n)}async function L(n){if(c!==void 0)return c;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module_or_path:n}=n:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof n>"u"&&(n=new URL("mq_wasm_bg.wasm",an.url));let e=U();(typeof n=="string"||typeof Request=="function"&&n instanceof Request||typeof URL=="function"&&n instanceof URL)&&(n=fetch(n));let{instance:t,module:r}=await sn(await n,e);return V(t,r)}var an,c,m,W,v,E,w,x,u,A,p,k,on,S,cn,P,I=C(()=>{"use strict";an={},m=null;W=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});W.decode();v=2146435072,E=0;w=new Array(128).fill(void 0);w.push(void 0,null,!0,!1);x=w.length;u=0,A=new TextEncoder;"encodeInto"in A||(A.encodeInto=function(n,e){let t=A.encode(n);return e.set(t),{read:n.length,written:t.length}});p=null;k=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>n.dtor(n.a,n.b));on=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>c.__wbg_runoptions_free(n>>>0,1)),S=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,on.unregister(this),e}free(){let e=this.__destroy_into_raw();c.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(S.prototype[Symbol.dispose]=S.prototype.free);cn=new Set(["basic","cors","default"]);P=L});var dn={};T(dn,{definedValues:()=>wn,diagnostics:()=>gn,format:()=>bn,run:()=>fn,toAst:()=>un});module.exports=N(dn);I();var j=null;async function F(){return j||(await(async()=>{try{await P();let n=await Promise.resolve().then(()=>(I(),B));j={run:n.run,toAst:n.toAst,format:n.format,diagnostics:n.diagnostics,definedValues:n.definedValues}}catch(n){throw new Error(`Failed to initialize mq WebAssembly module: ${n}`)}})(),j)}async function fn(n,e,t={}){return await(await F()).run(n,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...t})}async function un(n){return await(await F()).toAst(n)}async function bn(n){return await(await F()).format(n)}async function gn(n){return await(await F()).diagnostics(n)}async function wn(n,e){return await(await F()).definedValues(n,e)}0&&(module.exports={definedValues,diagnostics,format,run,toAst});
|
package/dist/core.d.cts
CHANGED
|
@@ -42,6 +42,6 @@ declare function diagnostics(code: string): Promise<ReadonlyArray<Diagnostic>>;
|
|
|
42
42
|
/**
|
|
43
43
|
* Get defined values from mq code
|
|
44
44
|
*/
|
|
45
|
-
declare function definedValues(code: string): Promise<ReadonlyArray<DefinedValue>>;
|
|
45
|
+
declare function definedValues(code: string, module?: string): Promise<ReadonlyArray<DefinedValue>>;
|
|
46
46
|
|
|
47
47
|
export { definedValues, diagnostics, format, run, toAst };
|
package/dist/core.d.ts
CHANGED
|
@@ -42,6 +42,6 @@ declare function diagnostics(code: string): Promise<ReadonlyArray<Diagnostic>>;
|
|
|
42
42
|
/**
|
|
43
43
|
* Get defined values from mq code
|
|
44
44
|
*/
|
|
45
|
-
declare function definedValues(code: string): Promise<ReadonlyArray<DefinedValue>>;
|
|
45
|
+
declare function definedValues(code: string, module?: string): Promise<ReadonlyArray<DefinedValue>>;
|
|
46
46
|
|
|
47
47
|
export { definedValues, diagnostics, format, run, toAst };
|
package/dist/core.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var
|
|
2
|
-
${t.stack}`:r}function G(t,e,n){let r,i;try{let l=o.__wbindgen_add_to_stack_pointer(-16),$=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),B=g,z=y(e,o.__wbindgen_export_0,o.__wbindgen_export_1),L=g;o.run(l,$,B,z,L,b(n));var _=a().getInt32(l+4*0,!0),s=a().getInt32(l+4*1,!0),f=a().getInt32(l+4*2,!0),u=a().getInt32(l+4*3,!0),d=_,m=s;if(u)throw d=0,m=0,w(f);return r=d,i=m,x(d,m)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(r,i,1)}}function K(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.toAst(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function Q(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.format(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function Z(t){let e=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),n=g,r=o.diagnostics(e,n);return w(r)}function tt(t){try{let i=o.__wbindgen_add_to_stack_pointer(-16),_=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;o.definedValues(i,_,s);var e=a().getInt32(i+4*0,!0),n=a().getInt32(i+4*1,!0),r=a().getInt32(i+4*2,!0);if(r)throw w(n);return w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}async function rt(t,e){if(typeof Response=="function"&&t instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(t,e)}catch(r){if(t.ok&&nt.has(t.type)&&t.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let n=await t.arrayBuffer();return await WebAssembly.instantiate(n,e)}else{let n=await WebAssembly.instantiate(t,e);return n instanceof WebAssembly.Instance?{instance:n,module:t}:n}}function V(){let t={};return t.wbg={},t.wbg.__wbg_Error_e17e777aac105295=function(e,n){let r=Error(x(e,n));return b(r)},t.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,n){let r=String(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_entries_2be2f15bd5554996=function(e){let n=Object.entries(c(e));return b(n)},t.wbg.__wbg_get_0da715ceaecea5c8=function(e,n){let r=c(e)[n>>>0];return b(r)},t.wbg.__wbg_getwithrefkey_1dc361bd10053bfe=function(e,n){let r=c(e)[c(n)];return b(r)},t.wbg.__wbg_instanceof_ArrayBuffer_67f3012529f6a2dd=function(e){let n;try{n=c(e)instanceof ArrayBuffer}catch{n=!1}return n},t.wbg.__wbg_instanceof_Uint8Array_9a8378d955933db7=function(e){let n;try{n=c(e)instanceof Uint8Array}catch{n=!1}return n},t.wbg.__wbg_length_186546c51cd61acd=function(e){return c(e).length},t.wbg.__wbg_length_6bb7e81f9d7713e4=function(e){return c(e).length},t.wbg.__wbg_new_19c25a3f2fa63a02=function(){let e=new Object;return b(e)},t.wbg.__wbg_new_1f3a344cf3123716=function(){let e=new Array;return b(e)},t.wbg.__wbg_new_638ebfaedbf32a5e=function(e){let n=new Uint8Array(c(e));return b(n)},t.wbg.__wbg_prototypesetcall_3d4a26c1ed734349=function(e,n,r){Uint8Array.prototype.set.call(H(e,n),c(r))},t.wbg.__wbg_set_3f1d0b984ed272ed=function(e,n,r){c(e)[w(n)]=w(r)},t.wbg.__wbg_set_90f6c0f7bd8c0415=function(e,n,r){c(e)[n>>>0]=w(r)},t.wbg.__wbg_wbindgenbooleanget_3fe6f642c7d97746=function(e){let n=c(e),r=typeof n=="boolean"?n:void 0;return E(r)?16777215:r?1:0},t.wbg.__wbg_wbindgendebugstring_99ef257a3ddda34d=function(e,n){let r=D(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_wbindgenin_d7a1ee10933d2d55=function(e,n){return c(e)in c(n)},t.wbg.__wbg_wbindgenisobject_307a53c6bd97fbf8=function(e){let n=c(e);return typeof n=="object"&&n!==null},t.wbg.__wbg_wbindgenisstring_d4fa939789f003b0=function(e){return typeof c(e)=="string"},t.wbg.__wbg_wbindgenisundefined_c4b71d073b92f3c5=function(e){return c(e)===void 0},t.wbg.__wbg_wbindgenjsvallooseeq_9bec8c9be826bed1=function(e,n){return c(e)==c(n)},t.wbg.__wbg_wbindgennumberget_f74b4c7525ac05cb=function(e,n){let r=c(n),i=typeof r=="number"?r:void 0;a().setFloat64(e+8*1,E(i)?0:i,!0),a().setInt32(e+4*0,!E(i),!0)},t.wbg.__wbg_wbindgenstringget_0f16a6ddddef376f=function(e,n){let r=c(n),i=typeof r=="string"?r:void 0;var _=E(i)?0:y(i,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;a().setInt32(e+4*1,s,!0),a().setInt32(e+4*0,_,!0)},t.wbg.__wbg_wbindgenthrow_451ec1a8469d7eb6=function(e,n){throw new Error(x(e,n))},t.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,n){let r=x(e,n);return b(r)},t.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return b(e)},t.wbg.__wbindgen_object_clone_ref=function(e){let n=c(e);return b(n)},t.wbg.__wbindgen_object_drop_ref=function(e){w(e)},t}function T(t,e){return o=t.exports,U.__wbindgen_wasm_module=e,h=null,A=null,o}function it(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module:t}=t:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=V();t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));let n=new WebAssembly.Instance(t,e);return T(n,t)}async function U(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module_or_path:t}=t:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof t>"u"&&(t=new URL("mq_wasm_bg.wasm",import.meta.url));let e=V();(typeof t=="string"||typeof Request=="function"&&t instanceof Request||typeof URL=="function"&&t instanceof URL)&&(t=fetch(t));let{instance:n,module:r}=await rt(await t,e);return T(n,r)}var o,A,F,X,M,p,S,g,O,h,et,j,nt,R,v=C(()=>{"use strict";A=null;F=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});F.decode();X=2146435072,M=0;p=new Array(128).fill(void 0);p.push(void 0,null,!0,!1);S=p.length;g=0,O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(t,e){let n=O.encode(t);return e.set(n),{read:t.length,written:n.length}});h=null;et=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(t=>o.__wbg_runoptions_free(t>>>0,1)),j=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,et.unregister(this),e}free(){let e=this.__destroy_into_raw();o.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(j.prototype[Symbol.dispose]=j.prototype.free);nt=new Set(["basic","cors","default"]);R=U});v();var k=null;async function W(){return k||(await(async()=>{try{await R();let t=await Promise.resolve().then(()=>(v(),P));k={run:t.run,toAst:t.toAst,format:t.format,diagnostics:t.diagnostics,definedValues:t.definedValues}}catch(t){throw new Error(`Failed to initialize mq WebAssembly module: ${t}`)}})(),k)}async function ft(t,e,n={}){return await(await W()).run(t,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...n})}async function ut(t){return await(await W()).toAst(t)}async function dt(t){return await(await W()).format(t)}async function bt(t){return await(await W()).diagnostics(t)}async function gt(t){return await(await W()).definedValues(t)}export{gt as definedValues,bt as diagnostics,dt as format,ft as run,ut as toAst};
|
|
1
|
+
var L=Object.defineProperty;var B=(n,e)=>()=>(n&&(e=n(n=0)),e);var z=(n,e)=>{for(var t in e)L(n,t,{get:e[t],enumerable:!0})};var V={};z(V,{RunOptions:()=>S,default:()=>R,definedValues:()=>J,diagnostics:()=>Y,format:()=>X,initSync:()=>tn,run:()=>v,toAst:()=>G});function h(){return(m===null||m.byteLength===0)&&(m=new Uint8Array(c.memory.buffer)),m}function $(n,e){return D+=e,D>=q&&(W=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),W.decode(),D=e),W.decode(h().subarray(n,n+e))}function O(n,e){return n=n>>>0,$(n,e)}function s(n){x===w.length&&w.push(w.length+1);let e=x;return x=w[e],w[e]=n,e}function o(n){return w[n]}function b(n,e,t){if(t===void 0){let f=A.encode(n),l=e(f.length,1)>>>0;return h().subarray(l,l+f.length).set(f),u=f.length,l}let r=n.length,i=e(r,1)>>>0,a=h(),_=0;for(;_<r;_++){let f=n.charCodeAt(_);if(f>127)break;a[i+_]=f}if(_!==r){_!==0&&(n=n.slice(_)),i=t(i,r,r=_+n.length*3,1)>>>0;let f=h().subarray(i+_,i+r),l=A.encodeInto(n,f);_+=l.written,i=t(i,r,_,1)>>>0}return u=_,i}function y(){return(p===null||p.buffer.detached===!0||p.buffer.detached===void 0&&p.buffer!==c.memory.buffer)&&(p=new DataView(c.memory.buffer)),p}function g(n){return n==null}function M(n){let e=typeof n;if(e=="number"||e=="boolean"||n==null)return`${n}`;if(e=="string")return`"${n}"`;if(e=="symbol"){let i=n.description;return i==null?"Symbol":`Symbol(${i})`}if(e=="function"){let i=n.name;return typeof i=="string"&&i.length>0?`Function(${i})`:"Function"}if(Array.isArray(n)){let i=n.length,a="[";i>0&&(a+=M(n[0]));for(let _=1;_<i;_++)a+=", "+M(n[_]);return a+="]",a}let t=/\[object ([^\]]+)\]/.exec(toString.call(n)),r;if(t&&t.length>1)r=t[1];else return toString.call(n);if(r=="Object")try{return"Object("+JSON.stringify(n)+")"}catch{return"Object"}return n instanceof Error?`${n.name}: ${n.message}
|
|
2
|
+
${n.stack}`:r}function E(n,e){try{return n.apply(this,e)}catch(t){c.__wbindgen_export3(s(t))}}function C(n,e){return n=n>>>0,h().subarray(n/1,n/1+e)}function H(n){n<132||(w[n]=x,x=n)}function d(n){let e=o(n);return H(n),e}function N(n,e,t,r){let i={a:n,b:e,cnt:1,dtor:t},a=(..._)=>{i.cnt++;let f=i.a;i.a=0;try{return r(f,i.b,..._)}finally{i.a=f,a._wbg_cb_unref()}};return a._wbg_cb_unref=()=>{--i.cnt===0&&(i.dtor(i.a,i.b),i.a=0,I.unregister(i))},I.register(a,i,i),a}function v(n,e,t){let r=b(n,c.__wbindgen_export,c.__wbindgen_export2),i=u,a=b(e,c.__wbindgen_export,c.__wbindgen_export2),_=u,f=c.run(r,i,a,_,s(t));return d(f)}function G(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.toAst(e,t);return d(r)}function X(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.format(e,t);return d(r)}function Y(n){let e=b(n,c.__wbindgen_export,c.__wbindgen_export2),t=u,r=c.diagnostics(e,t);return d(r)}function J(n,e){let t=b(n,c.__wbindgen_export,c.__wbindgen_export2),r=u;var i=g(e)?0:b(e,c.__wbindgen_export,c.__wbindgen_export2),a=u;let _=c.definedValues(t,r,i,a);return d(_)}function K(n,e,t){c.__wasm_bindgen_func_elem_2761(n,e,s(t))}function Q(n,e,t,r){c.__wasm_bindgen_func_elem_712(n,e,s(t),s(r))}async function en(n,e){if(typeof Response=="function"&&n instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(n,e)}catch(r){if(n.ok&&nn.has(n.type)&&n.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let t=await n.arrayBuffer();return await WebAssembly.instantiate(t,e)}else{let t=await WebAssembly.instantiate(n,e);return t instanceof WebAssembly.Instance?{instance:t,module:n}:t}}function T(){let n={};return n.wbg={},n.wbg.__wbg_Error_e83987f665cf5504=function(e,t){let r=Error(O(e,t));return s(r)},n.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,t){let r=String(o(t)),i=b(r,c.__wbindgen_export,c.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_boolean_get_6d5a1ee65bab5f68=function(e){let t=o(e),r=typeof t=="boolean"?t:void 0;return g(r)?16777215:r?1:0},n.wbg.__wbg___wbindgen_debug_string_df47ffb5e35e6763=function(e,t){let r=M(o(t)),i=b(r,c.__wbindgen_export,c.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_in_bb933bd9e1b3bc0f=function(e,t){return o(e)in o(t)},n.wbg.__wbg___wbindgen_is_function_ee8a6c5833c90377=function(e){return typeof o(e)=="function"},n.wbg.__wbg___wbindgen_is_object_c818261d21f283a4=function(e){let t=o(e);return typeof t=="object"&&t!==null},n.wbg.__wbg___wbindgen_is_string_fbb76cb2940daafd=function(e){return typeof o(e)=="string"},n.wbg.__wbg___wbindgen_is_undefined_2d472862bd29a478=function(e){return o(e)===void 0},n.wbg.__wbg___wbindgen_jsval_loose_eq_b664b38a2f582147=function(e,t){return o(e)==o(t)},n.wbg.__wbg___wbindgen_number_get_a20bf9b85341449d=function(e,t){let r=o(t),i=typeof r=="number"?r:void 0;y().setFloat64(e+8*1,g(i)?0:i,!0),y().setInt32(e+4*0,!g(i),!0)},n.wbg.__wbg___wbindgen_string_get_e4f06c90489ad01b=function(e,t){let r=o(t),i=typeof r=="string"?r:void 0;var a=g(i)?0:b(i,c.__wbindgen_export,c.__wbindgen_export2),_=u;y().setInt32(e+4*1,_,!0),y().setInt32(e+4*0,a,!0)},n.wbg.__wbg___wbindgen_throw_b855445ff6a94295=function(e,t){throw new Error(O(e,t))},n.wbg.__wbg__wbg_cb_unref_2454a539ea5790d9=function(e){o(e)._wbg_cb_unref()},n.wbg.__wbg_arrayBuffer_5930938a049abc90=function(e){let t=o(e).arrayBuffer();return s(t)},n.wbg.__wbg_call_525440f72fbfc0ea=function(){return E(function(e,t,r){let i=o(e).call(o(t),o(r));return s(i)},arguments)},n.wbg.__wbg_call_e762c39fa8ea36bf=function(){return E(function(e,t){let r=o(e).call(o(t));return s(r)},arguments)},n.wbg.__wbg_done_2042aa2670fb1db1=function(e){return o(e).done},n.wbg.__wbg_entries_a1e792d46512c8bf=function(e){let t=o(e).entries();return s(t)},n.wbg.__wbg_entries_e171b586f8f6bdbf=function(e){let t=Object.entries(o(e));return s(t)},n.wbg.__wbg_from_a4ad7cbddd0d7135=function(e){let t=Array.from(o(e));return s(t)},n.wbg.__wbg_getDirectory_7e7a55f640412401=function(e){let t=o(e).getDirectory();return s(t)},n.wbg.__wbg_getFile_985459d958bb9dfe=function(e){let t=o(e).getFile();return s(t)},n.wbg.__wbg_get_7bed016f185add81=function(e,t){let r=o(e)[t>>>0];return s(r)},n.wbg.__wbg_get_with_ref_key_1dc361bd10053bfe=function(e,t){let r=o(e)[o(t)];return s(r)},n.wbg.__wbg_instanceof_ArrayBuffer_70beb1189ca63b38=function(e){let t;try{t=o(e)instanceof ArrayBuffer}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemDirectoryHandle_7a17cc3353820fcf=function(e){let t;try{t=o(e)instanceof FileSystemDirectoryHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemFileHandle_5730ec1d120983f4=function(e){let t;try{t=o(e)instanceof FileSystemFileHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_Uint8Array_20c8e73002f7af98=function(e){let t;try{t=o(e)instanceof Uint8Array}catch{t=!1}return t},n.wbg.__wbg_instanceof_Window_4846dbb3de56c84c=function(e){let t;try{t=o(e)instanceof Window}catch{t=!1}return t},n.wbg.__wbg_length_69bca3cb64fc8748=function(e){return o(e).length},n.wbg.__wbg_length_cdd215e10d9dd507=function(e){return o(e).length},n.wbg.__wbg_navigator_971384882e8ea23a=function(e){let t=o(e).navigator;return s(t)},n.wbg.__wbg_new_1acc0b6eea89d040=function(){let e=new Object;return s(e)},n.wbg.__wbg_new_3c3d849046688a66=function(e,t){try{var r={a:e,b:t},i=(_,f)=>{let l=r.a;r.a=0;try{return Q(l,r.b,_,f)}finally{r.a=l}};let a=new Promise(i);return s(a)}finally{r.a=r.b=0}},n.wbg.__wbg_new_5a79be3ab53b8aa5=function(e){let t=new Uint8Array(o(e));return s(t)},n.wbg.__wbg_new_e17d9f43105b08be=function(){let e=new Array;return s(e)},n.wbg.__wbg_new_no_args_ee98eee5275000a4=function(e,t){let r=new Function(O(e,t));return s(r)},n.wbg.__wbg_next_eedaffcadc567b75=function(){return E(function(e){let t=o(e).next();return s(t)},arguments)},n.wbg.__wbg_prototypesetcall_2a6620b6922694b2=function(e,t,r){Uint8Array.prototype.set.call(C(e,t),o(r))},n.wbg.__wbg_queueMicrotask_34d692c25c47d05b=function(e){let t=o(e).queueMicrotask;return s(t)},n.wbg.__wbg_queueMicrotask_9d76cacb20c84d58=function(e){queueMicrotask(o(e))},n.wbg.__wbg_resolve_caf97c30b83f7053=function(e){let t=Promise.resolve(o(e));return s(t)},n.wbg.__wbg_set_3f1d0b984ed272ed=function(e,t,r){o(e)[d(t)]=d(r)},n.wbg.__wbg_set_c213c871859d6500=function(e,t,r){o(e)[t>>>0]=d(r)},n.wbg.__wbg_size_0a5a003dbf5dfee8=function(e){return o(e).size},n.wbg.__wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e=function(){let e=typeof global>"u"?null:global;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac=function(){let e=typeof globalThis>"u"?null:globalThis;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_SELF_6fdf4b64710cc91b=function(){let e=typeof self>"u"?null:self;return g(e)?0:s(e)},n.wbg.__wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2=function(){let e=typeof window>"u"?null:window;return g(e)?0:s(e)},n.wbg.__wbg_storage_3e7b84b6fbb9dd1c=function(e){let t=o(e).storage;return s(t)},n.wbg.__wbg_then_4f46f6544e6b4a28=function(e,t){let r=o(e).then(o(t));return s(r)},n.wbg.__wbg_then_70d05cf780a18d77=function(e,t,r){let i=o(e).then(o(t),o(r));return s(i)},n.wbg.__wbg_value_692627309814bb8c=function(e){let t=o(e).value;return s(t)},n.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,t){let r=O(e,t);return s(r)},n.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return s(e)},n.wbg.__wbindgen_cast_fd0586cfe4f12dd7=function(e,t){let r=N(e,t,c.__wasm_bindgen_func_elem_2760,K);return s(r)},n.wbg.__wbindgen_object_clone_ref=function(e){let t=o(e);return s(t)},n.wbg.__wbindgen_object_drop_ref=function(e){d(e)},n}function k(n,e){return c=n.exports,U.__wbindgen_wasm_module=e,p=null,m=null,c}function tn(n){if(c!==void 0)return c;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module:n}=n:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=T();n instanceof WebAssembly.Module||(n=new WebAssembly.Module(n));let t=new WebAssembly.Instance(n,e);return k(t,n)}async function U(n){if(c!==void 0)return c;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module_or_path:n}=n:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof n>"u"&&(n=new URL("mq_wasm_bg.wasm",import.meta.url));let e=T();(typeof n=="string"||typeof Request=="function"&&n instanceof Request||typeof URL=="function"&&n instanceof URL)&&(n=fetch(n));let{instance:t,module:r}=await en(await n,e);return k(t,r)}var c,m,W,q,D,w,x,u,A,p,I,Z,S,nn,R,P=B(()=>{"use strict";m=null;W=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});W.decode();q=2146435072,D=0;w=new Array(128).fill(void 0);w.push(void 0,null,!0,!1);x=w.length;u=0,A=new TextEncoder;"encodeInto"in A||(A.encodeInto=function(n,e){let t=A.encode(n);return e.set(t),{read:n.length,written:t.length}});p=null;I=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>n.dtor(n.a,n.b));Z=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>c.__wbg_runoptions_free(n>>>0,1)),S=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),e}free(){let e=this.__destroy_into_raw();c.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(S.prototype[Symbol.dispose]=S.prototype.free);nn=new Set(["basic","cors","default"]);R=U});P();var j=null;async function F(){return j||(await(async()=>{try{await R();let n=await Promise.resolve().then(()=>(P(),V));j={run:n.run,toAst:n.toAst,format:n.format,diagnostics:n.diagnostics,definedValues:n.definedValues}}catch(n){throw new Error(`Failed to initialize mq WebAssembly module: ${n}`)}})(),j)}async function an(n,e,t={}){return await(await F()).run(n,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...t})}async function fn(n){return await(await F()).toAst(n)}async function un(n){return await(await F()).format(n)}async function bn(n){return await(await F()).diagnostics(n)}async function gn(n,e){return await(await F()).definedValues(n,e)}export{gn as definedValues,bn as diagnostics,un as format,an as run,fn as toAst};
|
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var
|
|
2
|
-
${t.stack}`:r}function st(t,e,n){let r,i;try{let l=o.__wbindgen_add_to_stack_pointer(-16),X=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),Y=g,H=y(e,o.__wbindgen_export_0,o.__wbindgen_export_1),J=g;o.run(l,X,Y,H,J,b(n));var _=a().getInt32(l+4*0,!0),s=a().getInt32(l+4*1,!0),f=a().getInt32(l+4*2,!0),u=a().getInt32(l+4*3,!0),d=_,m=s;if(u)throw d=0,m=0,w(f);return r=d,i=m,x(d,m)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(r,i,1)}}function ct(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.toAst(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function at(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.format(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function _t(t){let e=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),n=g,r=o.diagnostics(e,n);return w(r)}function ft(t){try{let i=o.__wbindgen_add_to_stack_pointer(-16),_=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;o.definedValues(i,_,s);var e=a().getInt32(i+4*0,!0),n=a().getInt32(i+4*1,!0),r=a().getInt32(i+4*2,!0);if(r)throw w(n);return w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}async function bt(t,e){if(typeof Response=="function"&&t instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(t,e)}catch(r){if(t.ok&&dt.has(t.type)&&t.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let n=await t.arrayBuffer();return await WebAssembly.instantiate(n,e)}else{let n=await WebAssembly.instantiate(t,e);return n instanceof WebAssembly.Instance?{instance:n,module:t}:n}}function U(){let t={};return t.wbg={},t.wbg.__wbg_Error_e17e777aac105295=function(e,n){let r=Error(x(e,n));return b(r)},t.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,n){let r=String(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_entries_2be2f15bd5554996=function(e){let n=Object.entries(c(e));return b(n)},t.wbg.__wbg_get_0da715ceaecea5c8=function(e,n){let r=c(e)[n>>>0];return b(r)},t.wbg.__wbg_getwithrefkey_1dc361bd10053bfe=function(e,n){let r=c(e)[c(n)];return b(r)},t.wbg.__wbg_instanceof_ArrayBuffer_67f3012529f6a2dd=function(e){let n;try{n=c(e)instanceof ArrayBuffer}catch{n=!1}return n},t.wbg.__wbg_instanceof_Uint8Array_9a8378d955933db7=function(e){let n;try{n=c(e)instanceof Uint8Array}catch{n=!1}return n},t.wbg.__wbg_length_186546c51cd61acd=function(e){return c(e).length},t.wbg.__wbg_length_6bb7e81f9d7713e4=function(e){return c(e).length},t.wbg.__wbg_new_19c25a3f2fa63a02=function(){let e=new Object;return b(e)},t.wbg.__wbg_new_1f3a344cf3123716=function(){let e=new Array;return b(e)},t.wbg.__wbg_new_638ebfaedbf32a5e=function(e){let n=new Uint8Array(c(e));return b(n)},t.wbg.__wbg_prototypesetcall_3d4a26c1ed734349=function(e,n,r){Uint8Array.prototype.set.call(it(e,n),c(r))},t.wbg.__wbg_set_3f1d0b984ed272ed=function(e,n,r){c(e)[w(n)]=w(r)},t.wbg.__wbg_set_90f6c0f7bd8c0415=function(e,n,r){c(e)[n>>>0]=w(r)},t.wbg.__wbg_wbindgenbooleanget_3fe6f642c7d97746=function(e){let n=c(e),r=typeof n=="boolean"?n:void 0;return D(r)?16777215:r?1:0},t.wbg.__wbg_wbindgendebugstring_99ef257a3ddda34d=function(e,n){let r=V(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_wbindgenin_d7a1ee10933d2d55=function(e,n){return c(e)in c(n)},t.wbg.__wbg_wbindgenisobject_307a53c6bd97fbf8=function(e){let n=c(e);return typeof n=="object"&&n!==null},t.wbg.__wbg_wbindgenisstring_d4fa939789f003b0=function(e){return typeof c(e)=="string"},t.wbg.__wbg_wbindgenisundefined_c4b71d073b92f3c5=function(e){return c(e)===void 0},t.wbg.__wbg_wbindgenjsvallooseeq_9bec8c9be826bed1=function(e,n){return c(e)==c(n)},t.wbg.__wbg_wbindgennumberget_f74b4c7525ac05cb=function(e,n){let r=c(n),i=typeof r=="number"?r:void 0;a().setFloat64(e+8*1,D(i)?0:i,!0),a().setInt32(e+4*0,!D(i),!0)},t.wbg.__wbg_wbindgenstringget_0f16a6ddddef376f=function(e,n){let r=c(n),i=typeof r=="string"?r:void 0;var _=D(i)?0:y(i,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;a().setInt32(e+4*1,s,!0),a().setInt32(e+4*0,_,!0)},t.wbg.__wbg_wbindgenthrow_451ec1a8469d7eb6=function(e,n){throw new Error(x(e,n))},t.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,n){let r=x(e,n);return b(r)},t.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return b(e)},t.wbg.__wbindgen_object_clone_ref=function(e){let n=c(e);return b(n)},t.wbg.__wbindgen_object_drop_ref=function(e){w(e)},t}function P(t,e){return o=t.exports,$.__wbindgen_wasm_module=e,h=null,A=null,o}function gt(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module:t}=t:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=U();t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));let n=new WebAssembly.Instance(t,e);return P(n,t)}async function $(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module_or_path:t}=t:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof t>"u"&&(t=new URL("mq_wasm_bg.wasm",wt.url));let e=U();(typeof t=="string"||typeof Request=="function"&&t instanceof Request||typeof URL=="function"&&t instanceof URL)&&(t=fetch(t));let{instance:n,module:r}=await bt(await t,e);return P(n,r)}var wt,o,A,E,nt,M,p,S,g,O,h,ut,j,dt,R,v=Z(()=>{"use strict";wt={},A=null;E=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});E.decode();nt=2146435072,M=0;p=new Array(128).fill(void 0);p.push(void 0,null,!0,!1);S=p.length;g=0,O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(t,e){let n=O.encode(t);return e.set(n),{read:t.length,written:n.length}});h=null;ut=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(t=>o.__wbg_runoptions_free(t>>>0,1)),j=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,ut.unregister(this),e}free(){let e=this.__destroy_into_raw();o.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(j.prototype[Symbol.dispose]=j.prototype.free);dt=new Set(["basic","cors","default"]);R=$});var lt={};T(lt,{definedValues:()=>N,diagnostics:()=>C,format:()=>L,run:()=>B,toAst:()=>z});module.exports=et(lt);v();var F=null;async function W(){return F||(await(async()=>{try{await R();let t=await Promise.resolve().then(()=>(v(),q));F={run:t.run,toAst:t.toAst,format:t.format,diagnostics:t.diagnostics,definedValues:t.definedValues}}catch(t){throw new Error(`Failed to initialize mq WebAssembly module: ${t}`)}})(),F)}async function B(t,e,n={}){return await(await W()).run(t,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...n})}async function z(t){return await(await W()).toAst(t)}async function L(t){return await(await W()).format(t)}async function C(t){return await(await W()).diagnostics(t)}async function N(t){return await(await W()).definedValues(t)}0&&(module.exports={definedValues,diagnostics,format,run,toAst});
|
|
1
|
+
"use strict";var W=Object.defineProperty;var N=Object.getOwnPropertyDescriptor;var v=Object.getOwnPropertyNames;var G=Object.prototype.hasOwnProperty;var X=(n,e)=>()=>(n&&(e=n(n=0)),e);var T=(n,e)=>{for(var t in e)W(n,t,{get:e[t],enumerable:!0})},Y=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of v(e))!G.call(n,i)&&i!==t&&W(n,i,{get:()=>e[i],enumerable:!(r=N(e,i))||r.enumerable});return n};var J=n=>Y(W({},"__esModule",{value:!0}),n);var q={};T(q,{RunOptions:()=>S,default:()=>P,definedValues:()=>cn,diagnostics:()=>sn,format:()=>on,initSync:()=>gn,run:()=>tn,toAst:()=>rn});function h(){return(m===null||m.byteLength===0)&&(m=new Uint8Array(s.memory.buffer)),m}function Q(n,e){return E+=e,E>=K&&(D=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),D.decode(),E=e),D.decode(h().subarray(n,n+e))}function O(n,e){return n=n>>>0,Q(n,e)}function c(n){x===w.length&&w.push(w.length+1);let e=x;return x=w[e],w[e]=n,e}function o(n){return w[n]}function b(n,e,t){if(t===void 0){let f=A.encode(n),l=e(f.length,1)>>>0;return h().subarray(l,l+f.length).set(f),u=f.length,l}let r=n.length,i=e(r,1)>>>0,a=h(),_=0;for(;_<r;_++){let f=n.charCodeAt(_);if(f>127)break;a[i+_]=f}if(_!==r){_!==0&&(n=n.slice(_)),i=t(i,r,r=_+n.length*3,1)>>>0;let f=h().subarray(i+_,i+r),l=A.encodeInto(n,f);_+=l.written,i=t(i,r,_,1)>>>0}return u=_,i}function y(){return(p===null||p.buffer.detached===!0||p.buffer.detached===void 0&&p.buffer!==s.memory.buffer)&&(p=new DataView(s.memory.buffer)),p}function g(n){return n==null}function R(n){let e=typeof n;if(e=="number"||e=="boolean"||n==null)return`${n}`;if(e=="string")return`"${n}"`;if(e=="symbol"){let i=n.description;return i==null?"Symbol":`Symbol(${i})`}if(e=="function"){let i=n.name;return typeof i=="string"&&i.length>0?`Function(${i})`:"Function"}if(Array.isArray(n)){let i=n.length,a="[";i>0&&(a+=R(n[0]));for(let _=1;_<i;_++)a+=", "+R(n[_]);return a+="]",a}let t=/\[object ([^\]]+)\]/.exec(toString.call(n)),r;if(t&&t.length>1)r=t[1];else return toString.call(n);if(r=="Object")try{return"Object("+JSON.stringify(n)+")"}catch{return"Object"}return n instanceof Error?`${n.name}: ${n.message}
|
|
2
|
+
${n.stack}`:r}function M(n,e){try{return n.apply(this,e)}catch(t){s.__wbindgen_export3(c(t))}}function Z(n,e){return n=n>>>0,h().subarray(n/1,n/1+e)}function nn(n){n<132||(w[n]=x,x=n)}function d(n){let e=o(n);return nn(n),e}function en(n,e,t,r){let i={a:n,b:e,cnt:1,dtor:t},a=(..._)=>{i.cnt++;let f=i.a;i.a=0;try{return r(f,i.b,..._)}finally{i.a=f,a._wbg_cb_unref()}};return a._wbg_cb_unref=()=>{--i.cnt===0&&(i.dtor(i.a,i.b),i.a=0,V.unregister(i))},V.register(a,i,i),a}function tn(n,e,t){let r=b(n,s.__wbindgen_export,s.__wbindgen_export2),i=u,a=b(e,s.__wbindgen_export,s.__wbindgen_export2),_=u,f=s.run(r,i,a,_,c(t));return d(f)}function rn(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.toAst(e,t);return d(r)}function on(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.format(e,t);return d(r)}function sn(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.diagnostics(e,t);return d(r)}function cn(n,e){let t=b(n,s.__wbindgen_export,s.__wbindgen_export2),r=u;var i=g(e)?0:b(e,s.__wbindgen_export,s.__wbindgen_export2),a=u;let _=s.definedValues(t,r,i,a);return d(_)}function _n(n,e,t){s.__wasm_bindgen_func_elem_2761(n,e,c(t))}function an(n,e,t,r){s.__wasm_bindgen_func_elem_712(n,e,c(t),c(r))}async function bn(n,e){if(typeof Response=="function"&&n instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(n,e)}catch(r){if(n.ok&&un.has(n.type)&&n.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let t=await n.arrayBuffer();return await WebAssembly.instantiate(t,e)}else{let t=await WebAssembly.instantiate(n,e);return t instanceof WebAssembly.Instance?{instance:t,module:n}:t}}function k(){let n={};return n.wbg={},n.wbg.__wbg_Error_e83987f665cf5504=function(e,t){let r=Error(O(e,t));return c(r)},n.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,t){let r=String(o(t)),i=b(r,s.__wbindgen_export,s.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_boolean_get_6d5a1ee65bab5f68=function(e){let t=o(e),r=typeof t=="boolean"?t:void 0;return g(r)?16777215:r?1:0},n.wbg.__wbg___wbindgen_debug_string_df47ffb5e35e6763=function(e,t){let r=R(o(t)),i=b(r,s.__wbindgen_export,s.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_in_bb933bd9e1b3bc0f=function(e,t){return o(e)in o(t)},n.wbg.__wbg___wbindgen_is_function_ee8a6c5833c90377=function(e){return typeof o(e)=="function"},n.wbg.__wbg___wbindgen_is_object_c818261d21f283a4=function(e){let t=o(e);return typeof t=="object"&&t!==null},n.wbg.__wbg___wbindgen_is_string_fbb76cb2940daafd=function(e){return typeof o(e)=="string"},n.wbg.__wbg___wbindgen_is_undefined_2d472862bd29a478=function(e){return o(e)===void 0},n.wbg.__wbg___wbindgen_jsval_loose_eq_b664b38a2f582147=function(e,t){return o(e)==o(t)},n.wbg.__wbg___wbindgen_number_get_a20bf9b85341449d=function(e,t){let r=o(t),i=typeof r=="number"?r:void 0;y().setFloat64(e+8*1,g(i)?0:i,!0),y().setInt32(e+4*0,!g(i),!0)},n.wbg.__wbg___wbindgen_string_get_e4f06c90489ad01b=function(e,t){let r=o(t),i=typeof r=="string"?r:void 0;var a=g(i)?0:b(i,s.__wbindgen_export,s.__wbindgen_export2),_=u;y().setInt32(e+4*1,_,!0),y().setInt32(e+4*0,a,!0)},n.wbg.__wbg___wbindgen_throw_b855445ff6a94295=function(e,t){throw new Error(O(e,t))},n.wbg.__wbg__wbg_cb_unref_2454a539ea5790d9=function(e){o(e)._wbg_cb_unref()},n.wbg.__wbg_arrayBuffer_5930938a049abc90=function(e){let t=o(e).arrayBuffer();return c(t)},n.wbg.__wbg_call_525440f72fbfc0ea=function(){return M(function(e,t,r){let i=o(e).call(o(t),o(r));return c(i)},arguments)},n.wbg.__wbg_call_e762c39fa8ea36bf=function(){return M(function(e,t){let r=o(e).call(o(t));return c(r)},arguments)},n.wbg.__wbg_done_2042aa2670fb1db1=function(e){return o(e).done},n.wbg.__wbg_entries_a1e792d46512c8bf=function(e){let t=o(e).entries();return c(t)},n.wbg.__wbg_entries_e171b586f8f6bdbf=function(e){let t=Object.entries(o(e));return c(t)},n.wbg.__wbg_from_a4ad7cbddd0d7135=function(e){let t=Array.from(o(e));return c(t)},n.wbg.__wbg_getDirectory_7e7a55f640412401=function(e){let t=o(e).getDirectory();return c(t)},n.wbg.__wbg_getFile_985459d958bb9dfe=function(e){let t=o(e).getFile();return c(t)},n.wbg.__wbg_get_7bed016f185add81=function(e,t){let r=o(e)[t>>>0];return c(r)},n.wbg.__wbg_get_with_ref_key_1dc361bd10053bfe=function(e,t){let r=o(e)[o(t)];return c(r)},n.wbg.__wbg_instanceof_ArrayBuffer_70beb1189ca63b38=function(e){let t;try{t=o(e)instanceof ArrayBuffer}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemDirectoryHandle_7a17cc3353820fcf=function(e){let t;try{t=o(e)instanceof FileSystemDirectoryHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemFileHandle_5730ec1d120983f4=function(e){let t;try{t=o(e)instanceof FileSystemFileHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_Uint8Array_20c8e73002f7af98=function(e){let t;try{t=o(e)instanceof Uint8Array}catch{t=!1}return t},n.wbg.__wbg_instanceof_Window_4846dbb3de56c84c=function(e){let t;try{t=o(e)instanceof Window}catch{t=!1}return t},n.wbg.__wbg_length_69bca3cb64fc8748=function(e){return o(e).length},n.wbg.__wbg_length_cdd215e10d9dd507=function(e){return o(e).length},n.wbg.__wbg_navigator_971384882e8ea23a=function(e){let t=o(e).navigator;return c(t)},n.wbg.__wbg_new_1acc0b6eea89d040=function(){let e=new Object;return c(e)},n.wbg.__wbg_new_3c3d849046688a66=function(e,t){try{var r={a:e,b:t},i=(_,f)=>{let l=r.a;r.a=0;try{return an(l,r.b,_,f)}finally{r.a=l}};let a=new Promise(i);return c(a)}finally{r.a=r.b=0}},n.wbg.__wbg_new_5a79be3ab53b8aa5=function(e){let t=new Uint8Array(o(e));return c(t)},n.wbg.__wbg_new_e17d9f43105b08be=function(){let e=new Array;return c(e)},n.wbg.__wbg_new_no_args_ee98eee5275000a4=function(e,t){let r=new Function(O(e,t));return c(r)},n.wbg.__wbg_next_eedaffcadc567b75=function(){return M(function(e){let t=o(e).next();return c(t)},arguments)},n.wbg.__wbg_prototypesetcall_2a6620b6922694b2=function(e,t,r){Uint8Array.prototype.set.call(Z(e,t),o(r))},n.wbg.__wbg_queueMicrotask_34d692c25c47d05b=function(e){let t=o(e).queueMicrotask;return c(t)},n.wbg.__wbg_queueMicrotask_9d76cacb20c84d58=function(e){queueMicrotask(o(e))},n.wbg.__wbg_resolve_caf97c30b83f7053=function(e){let t=Promise.resolve(o(e));return c(t)},n.wbg.__wbg_set_3f1d0b984ed272ed=function(e,t,r){o(e)[d(t)]=d(r)},n.wbg.__wbg_set_c213c871859d6500=function(e,t,r){o(e)[t>>>0]=d(r)},n.wbg.__wbg_size_0a5a003dbf5dfee8=function(e){return o(e).size},n.wbg.__wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e=function(){let e=typeof global>"u"?null:global;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac=function(){let e=typeof globalThis>"u"?null:globalThis;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_SELF_6fdf4b64710cc91b=function(){let e=typeof self>"u"?null:self;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2=function(){let e=typeof window>"u"?null:window;return g(e)?0:c(e)},n.wbg.__wbg_storage_3e7b84b6fbb9dd1c=function(e){let t=o(e).storage;return c(t)},n.wbg.__wbg_then_4f46f6544e6b4a28=function(e,t){let r=o(e).then(o(t));return c(r)},n.wbg.__wbg_then_70d05cf780a18d77=function(e,t,r){let i=o(e).then(o(t),o(r));return c(i)},n.wbg.__wbg_value_692627309814bb8c=function(e){let t=o(e).value;return c(t)},n.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,t){let r=O(e,t);return c(r)},n.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return c(e)},n.wbg.__wbindgen_cast_fd0586cfe4f12dd7=function(e,t){let r=en(e,t,s.__wasm_bindgen_func_elem_2760,_n);return c(r)},n.wbg.__wbindgen_object_clone_ref=function(e){let t=o(e);return c(t)},n.wbg.__wbindgen_object_drop_ref=function(e){d(e)},n}function U(n,e){return s=n.exports,L.__wbindgen_wasm_module=e,p=null,m=null,s}function gn(n){if(s!==void 0)return s;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module:n}=n:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=k();n instanceof WebAssembly.Module||(n=new WebAssembly.Module(n));let t=new WebAssembly.Instance(n,e);return U(t,n)}async function L(n){if(s!==void 0)return s;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module_or_path:n}=n:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof n>"u"&&(n=new URL("mq_wasm_bg.wasm",wn.url));let e=k();(typeof n=="string"||typeof Request=="function"&&n instanceof Request||typeof URL=="function"&&n instanceof URL)&&(n=fetch(n));let{instance:t,module:r}=await bn(await n,e);return U(t,r)}var wn,s,m,D,K,E,w,x,u,A,p,V,fn,S,un,P,I=X(()=>{"use strict";wn={},m=null;D=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});D.decode();K=2146435072,E=0;w=new Array(128).fill(void 0);w.push(void 0,null,!0,!1);x=w.length;u=0,A=new TextEncoder;"encodeInto"in A||(A.encodeInto=function(n,e){let t=A.encode(n);return e.set(t),{read:n.length,written:t.length}});p=null;V=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>n.dtor(n.a,n.b));fn=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>s.__wbg_runoptions_free(n>>>0,1)),S=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,fn.unregister(this),e}free(){let e=this.__destroy_into_raw();s.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(S.prototype[Symbol.dispose]=S.prototype.free);un=new Set(["basic","cors","default"]);P=L});var dn={};T(dn,{definedValues:()=>H,diagnostics:()=>C,format:()=>$,run:()=>B,toAst:()=>z});module.exports=J(dn);I();var j=null;async function F(){return j||(await(async()=>{try{await P();let n=await Promise.resolve().then(()=>(I(),q));j={run:n.run,toAst:n.toAst,format:n.format,diagnostics:n.diagnostics,definedValues:n.definedValues}}catch(n){throw new Error(`Failed to initialize mq WebAssembly module: ${n}`)}})(),j)}async function B(n,e,t={}){return await(await F()).run(n,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...t})}async function z(n){return await(await F()).toAst(n)}async function $(n){return await(await F()).format(n)}async function C(n){return await(await F()).diagnostics(n)}async function H(n,e){return await(await F()).definedValues(n,e)}0&&(module.exports={definedValues,diagnostics,format,run,toAst});
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var L=Object.defineProperty;var
|
|
2
|
-
${t.stack}`:r}function G(t,e,n){let r,i;try{let l=o.__wbindgen_add_to_stack_pointer(-16),$=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),q=g,B=y(e,o.__wbindgen_export_0,o.__wbindgen_export_1),z=g;o.run(l,$,q,B,z,b(n));var _=a().getInt32(l+4*0,!0),s=a().getInt32(l+4*1,!0),f=a().getInt32(l+4*2,!0),u=a().getInt32(l+4*3,!0),d=_,m=s;if(u)throw d=0,m=0,w(f);return r=d,i=m,x(d,m)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(r,i,1)}}function K(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.toAst(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function Q(t){let e,n;try{let d=o.__wbindgen_add_to_stack_pointer(-16),m=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),l=g;o.format(d,m,l);var r=a().getInt32(d+4*0,!0),i=a().getInt32(d+4*1,!0),_=a().getInt32(d+4*2,!0),s=a().getInt32(d+4*3,!0),f=r,u=i;if(s)throw f=0,u=0,w(_);return e=f,n=u,x(f,u)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_export_2(e,n,1)}}function Z(t){let e=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),n=g,r=o.diagnostics(e,n);return w(r)}function tt(t){try{let i=o.__wbindgen_add_to_stack_pointer(-16),_=y(t,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;o.definedValues(i,_,s);var e=a().getInt32(i+4*0,!0),n=a().getInt32(i+4*1,!0),r=a().getInt32(i+4*2,!0);if(r)throw w(n);return w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}async function rt(t,e){if(typeof Response=="function"&&t instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(t,e)}catch(r){if(t.ok&&nt.has(t.type)&&t.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let n=await t.arrayBuffer();return await WebAssembly.instantiate(n,e)}else{let n=await WebAssembly.instantiate(t,e);return n instanceof WebAssembly.Instance?{instance:n,module:t}:n}}function v(){let t={};return t.wbg={},t.wbg.__wbg_Error_e17e777aac105295=function(e,n){let r=Error(x(e,n));return b(r)},t.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,n){let r=String(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_entries_2be2f15bd5554996=function(e){let n=Object.entries(c(e));return b(n)},t.wbg.__wbg_get_0da715ceaecea5c8=function(e,n){let r=c(e)[n>>>0];return b(r)},t.wbg.__wbg_getwithrefkey_1dc361bd10053bfe=function(e,n){let r=c(e)[c(n)];return b(r)},t.wbg.__wbg_instanceof_ArrayBuffer_67f3012529f6a2dd=function(e){let n;try{n=c(e)instanceof ArrayBuffer}catch{n=!1}return n},t.wbg.__wbg_instanceof_Uint8Array_9a8378d955933db7=function(e){let n;try{n=c(e)instanceof Uint8Array}catch{n=!1}return n},t.wbg.__wbg_length_186546c51cd61acd=function(e){return c(e).length},t.wbg.__wbg_length_6bb7e81f9d7713e4=function(e){return c(e).length},t.wbg.__wbg_new_19c25a3f2fa63a02=function(){let e=new Object;return b(e)},t.wbg.__wbg_new_1f3a344cf3123716=function(){let e=new Array;return b(e)},t.wbg.__wbg_new_638ebfaedbf32a5e=function(e){let n=new Uint8Array(c(e));return b(n)},t.wbg.__wbg_prototypesetcall_3d4a26c1ed734349=function(e,n,r){Uint8Array.prototype.set.call(H(e,n),c(r))},t.wbg.__wbg_set_3f1d0b984ed272ed=function(e,n,r){c(e)[w(n)]=w(r)},t.wbg.__wbg_set_90f6c0f7bd8c0415=function(e,n,r){c(e)[n>>>0]=w(r)},t.wbg.__wbg_wbindgenbooleanget_3fe6f642c7d97746=function(e){let n=c(e),r=typeof n=="boolean"?n:void 0;return D(r)?16777215:r?1:0},t.wbg.__wbg_wbindgendebugstring_99ef257a3ddda34d=function(e,n){let r=M(c(n)),i=y(r,o.__wbindgen_export_0,o.__wbindgen_export_1),_=g;a().setInt32(e+4*1,_,!0),a().setInt32(e+4*0,i,!0)},t.wbg.__wbg_wbindgenin_d7a1ee10933d2d55=function(e,n){return c(e)in c(n)},t.wbg.__wbg_wbindgenisobject_307a53c6bd97fbf8=function(e){let n=c(e);return typeof n=="object"&&n!==null},t.wbg.__wbg_wbindgenisstring_d4fa939789f003b0=function(e){return typeof c(e)=="string"},t.wbg.__wbg_wbindgenisundefined_c4b71d073b92f3c5=function(e){return c(e)===void 0},t.wbg.__wbg_wbindgenjsvallooseeq_9bec8c9be826bed1=function(e,n){return c(e)==c(n)},t.wbg.__wbg_wbindgennumberget_f74b4c7525ac05cb=function(e,n){let r=c(n),i=typeof r=="number"?r:void 0;a().setFloat64(e+8*1,D(i)?0:i,!0),a().setInt32(e+4*0,!D(i),!0)},t.wbg.__wbg_wbindgenstringget_0f16a6ddddef376f=function(e,n){let r=c(n),i=typeof r=="string"?r:void 0;var _=D(i)?0:y(i,o.__wbindgen_export_0,o.__wbindgen_export_1),s=g;a().setInt32(e+4*1,s,!0),a().setInt32(e+4*0,_,!0)},t.wbg.__wbg_wbindgenthrow_451ec1a8469d7eb6=function(e,n){throw new Error(x(e,n))},t.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,n){let r=x(e,n);return b(r)},t.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return b(e)},t.wbg.__wbindgen_object_clone_ref=function(e){let n=c(e);return b(n)},t.wbg.__wbindgen_object_drop_ref=function(e){w(e)},t}function T(t,e){return o=t.exports,U.__wbindgen_wasm_module=e,h=null,A=null,o}function it(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module:t}=t:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=v();t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));let n=new WebAssembly.Instance(t,e);return T(n,t)}async function U(t){if(o!==void 0)return o;typeof t<"u"&&(Object.getPrototypeOf(t)===Object.prototype?{module_or_path:t}=t:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof t>"u"&&(t=new URL("mq_wasm_bg.wasm",import.meta.url));let e=v();(typeof t=="string"||typeof Request=="function"&&t instanceof Request||typeof URL=="function"&&t instanceof URL)&&(t=fetch(t));let{instance:n,module:r}=await rt(await t,e);return T(n,r)}var o,A,E,X,k,p,S,g,O,h,et,j,nt,V,R=C(()=>{"use strict";A=null;E=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});E.decode();X=2146435072,k=0;p=new Array(128).fill(void 0);p.push(void 0,null,!0,!1);S=p.length;g=0,O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(t,e){let n=O.encode(t);return e.set(n),{read:t.length,written:n.length}});h=null;et=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(t=>o.__wbg_runoptions_free(t>>>0,1)),j=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,et.unregister(this),e}free(){let e=this.__destroy_into_raw();o.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(j.prototype[Symbol.dispose]=j.prototype.free);nt=new Set(["basic","cors","default"]);V=U});R();var F=null;async function W(){return F||(await(async()=>{try{await V();let t=await Promise.resolve().then(()=>(R(),P));F={run:t.run,toAst:t.toAst,format:t.format,diagnostics:t.diagnostics,definedValues:t.definedValues}}catch(t){throw new Error(`Failed to initialize mq WebAssembly module: ${t}`)}})(),F)}async function ot(t,e,n={}){return await(await W()).run(t,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...n})}async function st(t){return await(await W()).toAst(t)}async function ct(t){return await(await W()).format(t)}async function at(t){return await(await W()).diagnostics(t)}async function _t(t){return await(await W()).definedValues(t)}export{_t as definedValues,at as diagnostics,ct as format,ot as run,st as toAst};
|
|
1
|
+
var L=Object.defineProperty;var q=(n,e)=>()=>(n&&(e=n(n=0)),e);var B=(n,e)=>{for(var t in e)L(n,t,{get:e[t],enumerable:!0})};var U={};B(U,{RunOptions:()=>S,default:()=>R,definedValues:()=>J,diagnostics:()=>Y,format:()=>X,initSync:()=>tn,run:()=>v,toAst:()=>G});function h(){return(m===null||m.byteLength===0)&&(m=new Uint8Array(s.memory.buffer)),m}function $(n,e){return W+=e,W>=z&&(D=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),D.decode(),W=e),D.decode(h().subarray(n,n+e))}function O(n,e){return n=n>>>0,$(n,e)}function c(n){x===w.length&&w.push(w.length+1);let e=x;return x=w[e],w[e]=n,e}function o(n){return w[n]}function b(n,e,t){if(t===void 0){let f=A.encode(n),l=e(f.length,1)>>>0;return h().subarray(l,l+f.length).set(f),u=f.length,l}let r=n.length,i=e(r,1)>>>0,a=h(),_=0;for(;_<r;_++){let f=n.charCodeAt(_);if(f>127)break;a[i+_]=f}if(_!==r){_!==0&&(n=n.slice(_)),i=t(i,r,r=_+n.length*3,1)>>>0;let f=h().subarray(i+_,i+r),l=A.encodeInto(n,f);_+=l.written,i=t(i,r,_,1)>>>0}return u=_,i}function y(){return(p===null||p.buffer.detached===!0||p.buffer.detached===void 0&&p.buffer!==s.memory.buffer)&&(p=new DataView(s.memory.buffer)),p}function g(n){return n==null}function M(n){let e=typeof n;if(e=="number"||e=="boolean"||n==null)return`${n}`;if(e=="string")return`"${n}"`;if(e=="symbol"){let i=n.description;return i==null?"Symbol":`Symbol(${i})`}if(e=="function"){let i=n.name;return typeof i=="string"&&i.length>0?`Function(${i})`:"Function"}if(Array.isArray(n)){let i=n.length,a="[";i>0&&(a+=M(n[0]));for(let _=1;_<i;_++)a+=", "+M(n[_]);return a+="]",a}let t=/\[object ([^\]]+)\]/.exec(toString.call(n)),r;if(t&&t.length>1)r=t[1];else return toString.call(n);if(r=="Object")try{return"Object("+JSON.stringify(n)+")"}catch{return"Object"}return n instanceof Error?`${n.name}: ${n.message}
|
|
2
|
+
${n.stack}`:r}function E(n,e){try{return n.apply(this,e)}catch(t){s.__wbindgen_export3(c(t))}}function C(n,e){return n=n>>>0,h().subarray(n/1,n/1+e)}function H(n){n<132||(w[n]=x,x=n)}function d(n){let e=o(n);return H(n),e}function N(n,e,t,r){let i={a:n,b:e,cnt:1,dtor:t},a=(..._)=>{i.cnt++;let f=i.a;i.a=0;try{return r(f,i.b,..._)}finally{i.a=f,a._wbg_cb_unref()}};return a._wbg_cb_unref=()=>{--i.cnt===0&&(i.dtor(i.a,i.b),i.a=0,I.unregister(i))},I.register(a,i,i),a}function v(n,e,t){let r=b(n,s.__wbindgen_export,s.__wbindgen_export2),i=u,a=b(e,s.__wbindgen_export,s.__wbindgen_export2),_=u,f=s.run(r,i,a,_,c(t));return d(f)}function G(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.toAst(e,t);return d(r)}function X(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.format(e,t);return d(r)}function Y(n){let e=b(n,s.__wbindgen_export,s.__wbindgen_export2),t=u,r=s.diagnostics(e,t);return d(r)}function J(n,e){let t=b(n,s.__wbindgen_export,s.__wbindgen_export2),r=u;var i=g(e)?0:b(e,s.__wbindgen_export,s.__wbindgen_export2),a=u;let _=s.definedValues(t,r,i,a);return d(_)}function K(n,e,t){s.__wasm_bindgen_func_elem_2761(n,e,c(t))}function Q(n,e,t,r){s.__wasm_bindgen_func_elem_712(n,e,c(t),c(r))}async function en(n,e){if(typeof Response=="function"&&n instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return await WebAssembly.instantiateStreaming(n,e)}catch(r){if(n.ok&&nn.has(n.type)&&n.headers.get("Content-Type")!=="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",r);else throw r}let t=await n.arrayBuffer();return await WebAssembly.instantiate(t,e)}else{let t=await WebAssembly.instantiate(n,e);return t instanceof WebAssembly.Instance?{instance:t,module:n}:t}}function T(){let n={};return n.wbg={},n.wbg.__wbg_Error_e83987f665cf5504=function(e,t){let r=Error(O(e,t));return c(r)},n.wbg.__wbg_String_8f0eb39a4a4c2f66=function(e,t){let r=String(o(t)),i=b(r,s.__wbindgen_export,s.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_boolean_get_6d5a1ee65bab5f68=function(e){let t=o(e),r=typeof t=="boolean"?t:void 0;return g(r)?16777215:r?1:0},n.wbg.__wbg___wbindgen_debug_string_df47ffb5e35e6763=function(e,t){let r=M(o(t)),i=b(r,s.__wbindgen_export,s.__wbindgen_export2),a=u;y().setInt32(e+4*1,a,!0),y().setInt32(e+4*0,i,!0)},n.wbg.__wbg___wbindgen_in_bb933bd9e1b3bc0f=function(e,t){return o(e)in o(t)},n.wbg.__wbg___wbindgen_is_function_ee8a6c5833c90377=function(e){return typeof o(e)=="function"},n.wbg.__wbg___wbindgen_is_object_c818261d21f283a4=function(e){let t=o(e);return typeof t=="object"&&t!==null},n.wbg.__wbg___wbindgen_is_string_fbb76cb2940daafd=function(e){return typeof o(e)=="string"},n.wbg.__wbg___wbindgen_is_undefined_2d472862bd29a478=function(e){return o(e)===void 0},n.wbg.__wbg___wbindgen_jsval_loose_eq_b664b38a2f582147=function(e,t){return o(e)==o(t)},n.wbg.__wbg___wbindgen_number_get_a20bf9b85341449d=function(e,t){let r=o(t),i=typeof r=="number"?r:void 0;y().setFloat64(e+8*1,g(i)?0:i,!0),y().setInt32(e+4*0,!g(i),!0)},n.wbg.__wbg___wbindgen_string_get_e4f06c90489ad01b=function(e,t){let r=o(t),i=typeof r=="string"?r:void 0;var a=g(i)?0:b(i,s.__wbindgen_export,s.__wbindgen_export2),_=u;y().setInt32(e+4*1,_,!0),y().setInt32(e+4*0,a,!0)},n.wbg.__wbg___wbindgen_throw_b855445ff6a94295=function(e,t){throw new Error(O(e,t))},n.wbg.__wbg__wbg_cb_unref_2454a539ea5790d9=function(e){o(e)._wbg_cb_unref()},n.wbg.__wbg_arrayBuffer_5930938a049abc90=function(e){let t=o(e).arrayBuffer();return c(t)},n.wbg.__wbg_call_525440f72fbfc0ea=function(){return E(function(e,t,r){let i=o(e).call(o(t),o(r));return c(i)},arguments)},n.wbg.__wbg_call_e762c39fa8ea36bf=function(){return E(function(e,t){let r=o(e).call(o(t));return c(r)},arguments)},n.wbg.__wbg_done_2042aa2670fb1db1=function(e){return o(e).done},n.wbg.__wbg_entries_a1e792d46512c8bf=function(e){let t=o(e).entries();return c(t)},n.wbg.__wbg_entries_e171b586f8f6bdbf=function(e){let t=Object.entries(o(e));return c(t)},n.wbg.__wbg_from_a4ad7cbddd0d7135=function(e){let t=Array.from(o(e));return c(t)},n.wbg.__wbg_getDirectory_7e7a55f640412401=function(e){let t=o(e).getDirectory();return c(t)},n.wbg.__wbg_getFile_985459d958bb9dfe=function(e){let t=o(e).getFile();return c(t)},n.wbg.__wbg_get_7bed016f185add81=function(e,t){let r=o(e)[t>>>0];return c(r)},n.wbg.__wbg_get_with_ref_key_1dc361bd10053bfe=function(e,t){let r=o(e)[o(t)];return c(r)},n.wbg.__wbg_instanceof_ArrayBuffer_70beb1189ca63b38=function(e){let t;try{t=o(e)instanceof ArrayBuffer}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemDirectoryHandle_7a17cc3353820fcf=function(e){let t;try{t=o(e)instanceof FileSystemDirectoryHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_FileSystemFileHandle_5730ec1d120983f4=function(e){let t;try{t=o(e)instanceof FileSystemFileHandle}catch{t=!1}return t},n.wbg.__wbg_instanceof_Uint8Array_20c8e73002f7af98=function(e){let t;try{t=o(e)instanceof Uint8Array}catch{t=!1}return t},n.wbg.__wbg_instanceof_Window_4846dbb3de56c84c=function(e){let t;try{t=o(e)instanceof Window}catch{t=!1}return t},n.wbg.__wbg_length_69bca3cb64fc8748=function(e){return o(e).length},n.wbg.__wbg_length_cdd215e10d9dd507=function(e){return o(e).length},n.wbg.__wbg_navigator_971384882e8ea23a=function(e){let t=o(e).navigator;return c(t)},n.wbg.__wbg_new_1acc0b6eea89d040=function(){let e=new Object;return c(e)},n.wbg.__wbg_new_3c3d849046688a66=function(e,t){try{var r={a:e,b:t},i=(_,f)=>{let l=r.a;r.a=0;try{return Q(l,r.b,_,f)}finally{r.a=l}};let a=new Promise(i);return c(a)}finally{r.a=r.b=0}},n.wbg.__wbg_new_5a79be3ab53b8aa5=function(e){let t=new Uint8Array(o(e));return c(t)},n.wbg.__wbg_new_e17d9f43105b08be=function(){let e=new Array;return c(e)},n.wbg.__wbg_new_no_args_ee98eee5275000a4=function(e,t){let r=new Function(O(e,t));return c(r)},n.wbg.__wbg_next_eedaffcadc567b75=function(){return E(function(e){let t=o(e).next();return c(t)},arguments)},n.wbg.__wbg_prototypesetcall_2a6620b6922694b2=function(e,t,r){Uint8Array.prototype.set.call(C(e,t),o(r))},n.wbg.__wbg_queueMicrotask_34d692c25c47d05b=function(e){let t=o(e).queueMicrotask;return c(t)},n.wbg.__wbg_queueMicrotask_9d76cacb20c84d58=function(e){queueMicrotask(o(e))},n.wbg.__wbg_resolve_caf97c30b83f7053=function(e){let t=Promise.resolve(o(e));return c(t)},n.wbg.__wbg_set_3f1d0b984ed272ed=function(e,t,r){o(e)[d(t)]=d(r)},n.wbg.__wbg_set_c213c871859d6500=function(e,t,r){o(e)[t>>>0]=d(r)},n.wbg.__wbg_size_0a5a003dbf5dfee8=function(e){return o(e).size},n.wbg.__wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e=function(){let e=typeof global>"u"?null:global;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac=function(){let e=typeof globalThis>"u"?null:globalThis;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_SELF_6fdf4b64710cc91b=function(){let e=typeof self>"u"?null:self;return g(e)?0:c(e)},n.wbg.__wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2=function(){let e=typeof window>"u"?null:window;return g(e)?0:c(e)},n.wbg.__wbg_storage_3e7b84b6fbb9dd1c=function(e){let t=o(e).storage;return c(t)},n.wbg.__wbg_then_4f46f6544e6b4a28=function(e,t){let r=o(e).then(o(t));return c(r)},n.wbg.__wbg_then_70d05cf780a18d77=function(e,t,r){let i=o(e).then(o(t),o(r));return c(i)},n.wbg.__wbg_value_692627309814bb8c=function(e){let t=o(e).value;return c(t)},n.wbg.__wbindgen_cast_2241b6af4c4b2941=function(e,t){let r=O(e,t);return c(r)},n.wbg.__wbindgen_cast_d6cd19b81560fd6e=function(e){return c(e)},n.wbg.__wbindgen_cast_fd0586cfe4f12dd7=function(e,t){let r=N(e,t,s.__wasm_bindgen_func_elem_2760,K);return c(r)},n.wbg.__wbindgen_object_clone_ref=function(e){let t=o(e);return c(t)},n.wbg.__wbindgen_object_drop_ref=function(e){d(e)},n}function V(n,e){return s=n.exports,k.__wbindgen_wasm_module=e,p=null,m=null,s}function tn(n){if(s!==void 0)return s;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module:n}=n:console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));let e=T();n instanceof WebAssembly.Module||(n=new WebAssembly.Module(n));let t=new WebAssembly.Instance(n,e);return V(t,n)}async function k(n){if(s!==void 0)return s;typeof n<"u"&&(Object.getPrototypeOf(n)===Object.prototype?{module_or_path:n}=n:console.warn("using deprecated parameters for the initialization function; pass a single object instead")),typeof n>"u"&&(n=new URL("mq_wasm_bg.wasm",import.meta.url));let e=T();(typeof n=="string"||typeof Request=="function"&&n instanceof Request||typeof URL=="function"&&n instanceof URL)&&(n=fetch(n));let{instance:t,module:r}=await en(await n,e);return V(t,r)}var s,m,D,z,W,w,x,u,A,p,I,Z,S,nn,R,P=q(()=>{"use strict";m=null;D=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});D.decode();z=2146435072,W=0;w=new Array(128).fill(void 0);w.push(void 0,null,!0,!1);x=w.length;u=0,A=new TextEncoder;"encodeInto"in A||(A.encodeInto=function(n,e){let t=A.encode(n);return e.set(t),{read:n.length,written:t.length}});p=null;I=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>n.dtor(n.a,n.b));Z=typeof FinalizationRegistry>"u"?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(n=>s.__wbg_runoptions_free(n>>>0,1)),S=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),e}free(){let e=this.__destroy_into_raw();s.__wbg_runoptions_free(e,0)}};Symbol.dispose&&(S.prototype[Symbol.dispose]=S.prototype.free);nn=new Set(["basic","cors","default"]);R=k});P();var j=null;async function F(){return j||(await(async()=>{try{await R();let n=await Promise.resolve().then(()=>(P(),U));j={run:n.run,toAst:n.toAst,format:n.format,diagnostics:n.diagnostics,definedValues:n.definedValues}}catch(n){throw new Error(`Failed to initialize mq WebAssembly module: ${n}`)}})(),j)}async function rn(n,e,t={}){return await(await F()).run(n,e,{isUpdate:!1,inputFormat:"markdown",listStyle:"dash",linkUrlStyle:"none",linkTitleStyle:"paren",...t})}async function on(n){return await(await F()).toAst(n)}async function sn(n){return await(await F()).format(n)}async function cn(n){return await(await F()).diagnostics(n)}async function _n(n,e){return await(await F()).definedValues(n,e)}export{_n as definedValues,cn as diagnostics,sn as format,rn as run,on as toAst};
|
package/dist/mq_wasm.js
CHANGED
|
@@ -110,23 +110,6 @@ function getDataViewMemory0() {
|
|
|
110
110
|
return cachedDataViewMemory0;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
-
function getArrayU8FromWasm0(ptr, len) {
|
|
114
|
-
ptr = ptr >>> 0;
|
|
115
|
-
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
function dropObject(idx) {
|
|
119
|
-
if (idx < 132) return;
|
|
120
|
-
heap[idx] = heap_next;
|
|
121
|
-
heap_next = idx;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
function takeObject(idx) {
|
|
125
|
-
const ret = getObject(idx);
|
|
126
|
-
dropObject(idx);
|
|
127
|
-
return ret;
|
|
128
|
-
}
|
|
129
|
-
|
|
130
113
|
function isLikeNone(x) {
|
|
131
114
|
return x === undefined || x === null;
|
|
132
115
|
}
|
|
@@ -195,109 +178,106 @@ function debugString(val) {
|
|
|
195
178
|
// TODO we could test for more things here, like `Set`s and `Map`s.
|
|
196
179
|
return className;
|
|
197
180
|
}
|
|
181
|
+
|
|
182
|
+
function handleError(f, args) {
|
|
183
|
+
try {
|
|
184
|
+
return f.apply(this, args);
|
|
185
|
+
} catch (e) {
|
|
186
|
+
wasm.__wbindgen_export3(addHeapObject(e));
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
function getArrayU8FromWasm0(ptr, len) {
|
|
191
|
+
ptr = ptr >>> 0;
|
|
192
|
+
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
function dropObject(idx) {
|
|
196
|
+
if (idx < 132) return;
|
|
197
|
+
heap[idx] = heap_next;
|
|
198
|
+
heap_next = idx;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
function takeObject(idx) {
|
|
202
|
+
const ret = getObject(idx);
|
|
203
|
+
dropObject(idx);
|
|
204
|
+
return ret;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
|
|
208
|
+
? { register: () => {}, unregister: () => {} }
|
|
209
|
+
: new FinalizationRegistry(state => state.dtor(state.a, state.b));
|
|
210
|
+
|
|
211
|
+
function makeMutClosure(arg0, arg1, dtor, f) {
|
|
212
|
+
const state = { a: arg0, b: arg1, cnt: 1, dtor };
|
|
213
|
+
const real = (...args) => {
|
|
214
|
+
|
|
215
|
+
// First up with a closure we increment the internal reference
|
|
216
|
+
// count. This ensures that the Rust closure environment won't
|
|
217
|
+
// be deallocated while we're invoking it.
|
|
218
|
+
state.cnt++;
|
|
219
|
+
const a = state.a;
|
|
220
|
+
state.a = 0;
|
|
221
|
+
try {
|
|
222
|
+
return f(a, state.b, ...args);
|
|
223
|
+
} finally {
|
|
224
|
+
state.a = a;
|
|
225
|
+
real._wbg_cb_unref();
|
|
226
|
+
}
|
|
227
|
+
};
|
|
228
|
+
real._wbg_cb_unref = () => {
|
|
229
|
+
if (--state.cnt === 0) {
|
|
230
|
+
state.dtor(state.a, state.b);
|
|
231
|
+
state.a = 0;
|
|
232
|
+
CLOSURE_DTORS.unregister(state);
|
|
233
|
+
}
|
|
234
|
+
};
|
|
235
|
+
CLOSURE_DTORS.register(real, state, state);
|
|
236
|
+
return real;
|
|
237
|
+
}
|
|
198
238
|
/**
|
|
199
239
|
* @param {string} code
|
|
200
240
|
* @param {string} content
|
|
201
241
|
* @param {any} options
|
|
202
|
-
* @returns {string}
|
|
242
|
+
* @returns {Promise<string>}
|
|
203
243
|
*/
|
|
204
244
|
export function run(code, content, options) {
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
const ptr1 = passStringToWasm0(content, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
212
|
-
const len1 = WASM_VECTOR_LEN;
|
|
213
|
-
wasm.run(retptr, ptr0, len0, ptr1, len1, addHeapObject(options));
|
|
214
|
-
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
215
|
-
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
216
|
-
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
217
|
-
var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
|
|
218
|
-
var ptr3 = r0;
|
|
219
|
-
var len3 = r1;
|
|
220
|
-
if (r3) {
|
|
221
|
-
ptr3 = 0; len3 = 0;
|
|
222
|
-
throw takeObject(r2);
|
|
223
|
-
}
|
|
224
|
-
deferred4_0 = ptr3;
|
|
225
|
-
deferred4_1 = len3;
|
|
226
|
-
return getStringFromWasm0(ptr3, len3);
|
|
227
|
-
} finally {
|
|
228
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
229
|
-
wasm.__wbindgen_export_2(deferred4_0, deferred4_1, 1);
|
|
230
|
-
}
|
|
245
|
+
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
246
|
+
const len0 = WASM_VECTOR_LEN;
|
|
247
|
+
const ptr1 = passStringToWasm0(content, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
248
|
+
const len1 = WASM_VECTOR_LEN;
|
|
249
|
+
const ret = wasm.run(ptr0, len0, ptr1, len1, addHeapObject(options));
|
|
250
|
+
return takeObject(ret);
|
|
231
251
|
}
|
|
232
252
|
|
|
233
253
|
/**
|
|
234
254
|
* @param {string} code
|
|
235
|
-
* @returns {string}
|
|
255
|
+
* @returns {Promise<string>}
|
|
236
256
|
*/
|
|
237
257
|
export function toAst(code) {
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
243
|
-
const len0 = WASM_VECTOR_LEN;
|
|
244
|
-
wasm.toAst(retptr, ptr0, len0);
|
|
245
|
-
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
246
|
-
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
247
|
-
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
248
|
-
var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
|
|
249
|
-
var ptr2 = r0;
|
|
250
|
-
var len2 = r1;
|
|
251
|
-
if (r3) {
|
|
252
|
-
ptr2 = 0; len2 = 0;
|
|
253
|
-
throw takeObject(r2);
|
|
254
|
-
}
|
|
255
|
-
deferred3_0 = ptr2;
|
|
256
|
-
deferred3_1 = len2;
|
|
257
|
-
return getStringFromWasm0(ptr2, len2);
|
|
258
|
-
} finally {
|
|
259
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
260
|
-
wasm.__wbindgen_export_2(deferred3_0, deferred3_1, 1);
|
|
261
|
-
}
|
|
258
|
+
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
259
|
+
const len0 = WASM_VECTOR_LEN;
|
|
260
|
+
const ret = wasm.toAst(ptr0, len0);
|
|
261
|
+
return takeObject(ret);
|
|
262
262
|
}
|
|
263
263
|
|
|
264
264
|
/**
|
|
265
265
|
* @param {string} code
|
|
266
|
-
* @returns {string}
|
|
266
|
+
* @returns {Promise<string>}
|
|
267
267
|
*/
|
|
268
268
|
export function format(code) {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
274
|
-
const len0 = WASM_VECTOR_LEN;
|
|
275
|
-
wasm.format(retptr, ptr0, len0);
|
|
276
|
-
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
277
|
-
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
278
|
-
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
279
|
-
var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
|
|
280
|
-
var ptr2 = r0;
|
|
281
|
-
var len2 = r1;
|
|
282
|
-
if (r3) {
|
|
283
|
-
ptr2 = 0; len2 = 0;
|
|
284
|
-
throw takeObject(r2);
|
|
285
|
-
}
|
|
286
|
-
deferred3_0 = ptr2;
|
|
287
|
-
deferred3_1 = len2;
|
|
288
|
-
return getStringFromWasm0(ptr2, len2);
|
|
289
|
-
} finally {
|
|
290
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
291
|
-
wasm.__wbindgen_export_2(deferred3_0, deferred3_1, 1);
|
|
292
|
-
}
|
|
269
|
+
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
270
|
+
const len0 = WASM_VECTOR_LEN;
|
|
271
|
+
const ret = wasm.format(ptr0, len0);
|
|
272
|
+
return takeObject(ret);
|
|
293
273
|
}
|
|
294
274
|
|
|
295
275
|
/**
|
|
296
276
|
* @param {string} code
|
|
297
|
-
* @returns {any}
|
|
277
|
+
* @returns {Promise<any>}
|
|
298
278
|
*/
|
|
299
279
|
export function diagnostics(code) {
|
|
300
|
-
const ptr0 = passStringToWasm0(code, wasm.
|
|
280
|
+
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
301
281
|
const len0 = WASM_VECTOR_LEN;
|
|
302
282
|
const ret = wasm.diagnostics(ptr0, len0);
|
|
303
283
|
return takeObject(ret);
|
|
@@ -305,24 +285,24 @@ export function diagnostics(code) {
|
|
|
305
285
|
|
|
306
286
|
/**
|
|
307
287
|
* @param {string} code
|
|
308
|
-
* @
|
|
288
|
+
* @param {string | null} [module]
|
|
289
|
+
* @returns {Promise<any>}
|
|
309
290
|
*/
|
|
310
|
-
export function definedValues(code) {
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
}
|
|
291
|
+
export function definedValues(code, module) {
|
|
292
|
+
const ptr0 = passStringToWasm0(code, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
293
|
+
const len0 = WASM_VECTOR_LEN;
|
|
294
|
+
var ptr1 = isLikeNone(module) ? 0 : passStringToWasm0(module, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
295
|
+
var len1 = WASM_VECTOR_LEN;
|
|
296
|
+
const ret = wasm.definedValues(ptr0, len0, ptr1, len1);
|
|
297
|
+
return takeObject(ret);
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
function __wasm_bindgen_func_elem_2761(arg0, arg1, arg2) {
|
|
301
|
+
wasm.__wasm_bindgen_func_elem_2761(arg0, arg1, addHeapObject(arg2));
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
function __wasm_bindgen_func_elem_712(arg0, arg1, arg2, arg3) {
|
|
305
|
+
wasm.__wasm_bindgen_func_elem_712(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
|
326
306
|
}
|
|
327
307
|
|
|
328
308
|
const RunOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
@@ -383,30 +363,119 @@ async function __wbg_load(module, imports) {
|
|
|
383
363
|
function __wbg_get_imports() {
|
|
384
364
|
const imports = {};
|
|
385
365
|
imports.wbg = {};
|
|
386
|
-
imports.wbg.
|
|
366
|
+
imports.wbg.__wbg_Error_e83987f665cf5504 = function(arg0, arg1) {
|
|
387
367
|
const ret = Error(getStringFromWasm0(arg0, arg1));
|
|
388
368
|
return addHeapObject(ret);
|
|
389
369
|
};
|
|
390
370
|
imports.wbg.__wbg_String_8f0eb39a4a4c2f66 = function(arg0, arg1) {
|
|
391
371
|
const ret = String(getObject(arg1));
|
|
392
|
-
const ptr1 = passStringToWasm0(ret, wasm.
|
|
372
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
373
|
+
const len1 = WASM_VECTOR_LEN;
|
|
374
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
375
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
376
|
+
};
|
|
377
|
+
imports.wbg.__wbg___wbindgen_boolean_get_6d5a1ee65bab5f68 = function(arg0) {
|
|
378
|
+
const v = getObject(arg0);
|
|
379
|
+
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
380
|
+
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
381
|
+
};
|
|
382
|
+
imports.wbg.__wbg___wbindgen_debug_string_df47ffb5e35e6763 = function(arg0, arg1) {
|
|
383
|
+
const ret = debugString(getObject(arg1));
|
|
384
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
393
385
|
const len1 = WASM_VECTOR_LEN;
|
|
394
386
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
395
387
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
396
388
|
};
|
|
397
|
-
imports.wbg.
|
|
389
|
+
imports.wbg.__wbg___wbindgen_in_bb933bd9e1b3bc0f = function(arg0, arg1) {
|
|
390
|
+
const ret = getObject(arg0) in getObject(arg1);
|
|
391
|
+
return ret;
|
|
392
|
+
};
|
|
393
|
+
imports.wbg.__wbg___wbindgen_is_function_ee8a6c5833c90377 = function(arg0) {
|
|
394
|
+
const ret = typeof(getObject(arg0)) === 'function';
|
|
395
|
+
return ret;
|
|
396
|
+
};
|
|
397
|
+
imports.wbg.__wbg___wbindgen_is_object_c818261d21f283a4 = function(arg0) {
|
|
398
|
+
const val = getObject(arg0);
|
|
399
|
+
const ret = typeof(val) === 'object' && val !== null;
|
|
400
|
+
return ret;
|
|
401
|
+
};
|
|
402
|
+
imports.wbg.__wbg___wbindgen_is_string_fbb76cb2940daafd = function(arg0) {
|
|
403
|
+
const ret = typeof(getObject(arg0)) === 'string';
|
|
404
|
+
return ret;
|
|
405
|
+
};
|
|
406
|
+
imports.wbg.__wbg___wbindgen_is_undefined_2d472862bd29a478 = function(arg0) {
|
|
407
|
+
const ret = getObject(arg0) === undefined;
|
|
408
|
+
return ret;
|
|
409
|
+
};
|
|
410
|
+
imports.wbg.__wbg___wbindgen_jsval_loose_eq_b664b38a2f582147 = function(arg0, arg1) {
|
|
411
|
+
const ret = getObject(arg0) == getObject(arg1);
|
|
412
|
+
return ret;
|
|
413
|
+
};
|
|
414
|
+
imports.wbg.__wbg___wbindgen_number_get_a20bf9b85341449d = function(arg0, arg1) {
|
|
415
|
+
const obj = getObject(arg1);
|
|
416
|
+
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
417
|
+
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
418
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
419
|
+
};
|
|
420
|
+
imports.wbg.__wbg___wbindgen_string_get_e4f06c90489ad01b = function(arg0, arg1) {
|
|
421
|
+
const obj = getObject(arg1);
|
|
422
|
+
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
423
|
+
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
424
|
+
var len1 = WASM_VECTOR_LEN;
|
|
425
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
426
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
427
|
+
};
|
|
428
|
+
imports.wbg.__wbg___wbindgen_throw_b855445ff6a94295 = function(arg0, arg1) {
|
|
429
|
+
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
430
|
+
};
|
|
431
|
+
imports.wbg.__wbg__wbg_cb_unref_2454a539ea5790d9 = function(arg0) {
|
|
432
|
+
getObject(arg0)._wbg_cb_unref();
|
|
433
|
+
};
|
|
434
|
+
imports.wbg.__wbg_arrayBuffer_5930938a049abc90 = function(arg0) {
|
|
435
|
+
const ret = getObject(arg0).arrayBuffer();
|
|
436
|
+
return addHeapObject(ret);
|
|
437
|
+
};
|
|
438
|
+
imports.wbg.__wbg_call_525440f72fbfc0ea = function() { return handleError(function (arg0, arg1, arg2) {
|
|
439
|
+
const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
|
|
440
|
+
return addHeapObject(ret);
|
|
441
|
+
}, arguments) };
|
|
442
|
+
imports.wbg.__wbg_call_e762c39fa8ea36bf = function() { return handleError(function (arg0, arg1) {
|
|
443
|
+
const ret = getObject(arg0).call(getObject(arg1));
|
|
444
|
+
return addHeapObject(ret);
|
|
445
|
+
}, arguments) };
|
|
446
|
+
imports.wbg.__wbg_done_2042aa2670fb1db1 = function(arg0) {
|
|
447
|
+
const ret = getObject(arg0).done;
|
|
448
|
+
return ret;
|
|
449
|
+
};
|
|
450
|
+
imports.wbg.__wbg_entries_a1e792d46512c8bf = function(arg0) {
|
|
451
|
+
const ret = getObject(arg0).entries();
|
|
452
|
+
return addHeapObject(ret);
|
|
453
|
+
};
|
|
454
|
+
imports.wbg.__wbg_entries_e171b586f8f6bdbf = function(arg0) {
|
|
398
455
|
const ret = Object.entries(getObject(arg0));
|
|
399
456
|
return addHeapObject(ret);
|
|
400
457
|
};
|
|
401
|
-
imports.wbg.
|
|
458
|
+
imports.wbg.__wbg_from_a4ad7cbddd0d7135 = function(arg0) {
|
|
459
|
+
const ret = Array.from(getObject(arg0));
|
|
460
|
+
return addHeapObject(ret);
|
|
461
|
+
};
|
|
462
|
+
imports.wbg.__wbg_getDirectory_7e7a55f640412401 = function(arg0) {
|
|
463
|
+
const ret = getObject(arg0).getDirectory();
|
|
464
|
+
return addHeapObject(ret);
|
|
465
|
+
};
|
|
466
|
+
imports.wbg.__wbg_getFile_985459d958bb9dfe = function(arg0) {
|
|
467
|
+
const ret = getObject(arg0).getFile();
|
|
468
|
+
return addHeapObject(ret);
|
|
469
|
+
};
|
|
470
|
+
imports.wbg.__wbg_get_7bed016f185add81 = function(arg0, arg1) {
|
|
402
471
|
const ret = getObject(arg0)[arg1 >>> 0];
|
|
403
472
|
return addHeapObject(ret);
|
|
404
473
|
};
|
|
405
|
-
imports.wbg.
|
|
474
|
+
imports.wbg.__wbg_get_with_ref_key_1dc361bd10053bfe = function(arg0, arg1) {
|
|
406
475
|
const ret = getObject(arg0)[getObject(arg1)];
|
|
407
476
|
return addHeapObject(ret);
|
|
408
477
|
};
|
|
409
|
-
imports.wbg.
|
|
478
|
+
imports.wbg.__wbg_instanceof_ArrayBuffer_70beb1189ca63b38 = function(arg0) {
|
|
410
479
|
let result;
|
|
411
480
|
try {
|
|
412
481
|
result = getObject(arg0) instanceof ArrayBuffer;
|
|
@@ -416,7 +485,27 @@ function __wbg_get_imports() {
|
|
|
416
485
|
const ret = result;
|
|
417
486
|
return ret;
|
|
418
487
|
};
|
|
419
|
-
imports.wbg.
|
|
488
|
+
imports.wbg.__wbg_instanceof_FileSystemDirectoryHandle_7a17cc3353820fcf = function(arg0) {
|
|
489
|
+
let result;
|
|
490
|
+
try {
|
|
491
|
+
result = getObject(arg0) instanceof FileSystemDirectoryHandle;
|
|
492
|
+
} catch (_) {
|
|
493
|
+
result = false;
|
|
494
|
+
}
|
|
495
|
+
const ret = result;
|
|
496
|
+
return ret;
|
|
497
|
+
};
|
|
498
|
+
imports.wbg.__wbg_instanceof_FileSystemFileHandle_5730ec1d120983f4 = function(arg0) {
|
|
499
|
+
let result;
|
|
500
|
+
try {
|
|
501
|
+
result = getObject(arg0) instanceof FileSystemFileHandle;
|
|
502
|
+
} catch (_) {
|
|
503
|
+
result = false;
|
|
504
|
+
}
|
|
505
|
+
const ret = result;
|
|
506
|
+
return ret;
|
|
507
|
+
};
|
|
508
|
+
imports.wbg.__wbg_instanceof_Uint8Array_20c8e73002f7af98 = function(arg0) {
|
|
420
509
|
let result;
|
|
421
510
|
try {
|
|
422
511
|
result = getObject(arg0) instanceof Uint8Array;
|
|
@@ -426,84 +515,121 @@ function __wbg_get_imports() {
|
|
|
426
515
|
const ret = result;
|
|
427
516
|
return ret;
|
|
428
517
|
};
|
|
429
|
-
imports.wbg.
|
|
518
|
+
imports.wbg.__wbg_instanceof_Window_4846dbb3de56c84c = function(arg0) {
|
|
519
|
+
let result;
|
|
520
|
+
try {
|
|
521
|
+
result = getObject(arg0) instanceof Window;
|
|
522
|
+
} catch (_) {
|
|
523
|
+
result = false;
|
|
524
|
+
}
|
|
525
|
+
const ret = result;
|
|
526
|
+
return ret;
|
|
527
|
+
};
|
|
528
|
+
imports.wbg.__wbg_length_69bca3cb64fc8748 = function(arg0) {
|
|
430
529
|
const ret = getObject(arg0).length;
|
|
431
530
|
return ret;
|
|
432
531
|
};
|
|
433
|
-
imports.wbg.
|
|
532
|
+
imports.wbg.__wbg_length_cdd215e10d9dd507 = function(arg0) {
|
|
434
533
|
const ret = getObject(arg0).length;
|
|
435
534
|
return ret;
|
|
436
535
|
};
|
|
437
|
-
imports.wbg.
|
|
536
|
+
imports.wbg.__wbg_navigator_971384882e8ea23a = function(arg0) {
|
|
537
|
+
const ret = getObject(arg0).navigator;
|
|
538
|
+
return addHeapObject(ret);
|
|
539
|
+
};
|
|
540
|
+
imports.wbg.__wbg_new_1acc0b6eea89d040 = function() {
|
|
438
541
|
const ret = new Object();
|
|
439
542
|
return addHeapObject(ret);
|
|
440
543
|
};
|
|
441
|
-
imports.wbg.
|
|
544
|
+
imports.wbg.__wbg_new_3c3d849046688a66 = function(arg0, arg1) {
|
|
545
|
+
try {
|
|
546
|
+
var state0 = {a: arg0, b: arg1};
|
|
547
|
+
var cb0 = (arg0, arg1) => {
|
|
548
|
+
const a = state0.a;
|
|
549
|
+
state0.a = 0;
|
|
550
|
+
try {
|
|
551
|
+
return __wasm_bindgen_func_elem_712(a, state0.b, arg0, arg1);
|
|
552
|
+
} finally {
|
|
553
|
+
state0.a = a;
|
|
554
|
+
}
|
|
555
|
+
};
|
|
556
|
+
const ret = new Promise(cb0);
|
|
557
|
+
return addHeapObject(ret);
|
|
558
|
+
} finally {
|
|
559
|
+
state0.a = state0.b = 0;
|
|
560
|
+
}
|
|
561
|
+
};
|
|
562
|
+
imports.wbg.__wbg_new_5a79be3ab53b8aa5 = function(arg0) {
|
|
563
|
+
const ret = new Uint8Array(getObject(arg0));
|
|
564
|
+
return addHeapObject(ret);
|
|
565
|
+
};
|
|
566
|
+
imports.wbg.__wbg_new_e17d9f43105b08be = function() {
|
|
442
567
|
const ret = new Array();
|
|
443
568
|
return addHeapObject(ret);
|
|
444
569
|
};
|
|
445
|
-
imports.wbg.
|
|
446
|
-
const ret = new
|
|
570
|
+
imports.wbg.__wbg_new_no_args_ee98eee5275000a4 = function(arg0, arg1) {
|
|
571
|
+
const ret = new Function(getStringFromWasm0(arg0, arg1));
|
|
447
572
|
return addHeapObject(ret);
|
|
448
573
|
};
|
|
449
|
-
imports.wbg.
|
|
574
|
+
imports.wbg.__wbg_next_eedaffcadc567b75 = function() { return handleError(function (arg0) {
|
|
575
|
+
const ret = getObject(arg0).next();
|
|
576
|
+
return addHeapObject(ret);
|
|
577
|
+
}, arguments) };
|
|
578
|
+
imports.wbg.__wbg_prototypesetcall_2a6620b6922694b2 = function(arg0, arg1, arg2) {
|
|
450
579
|
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
|
|
451
580
|
};
|
|
581
|
+
imports.wbg.__wbg_queueMicrotask_34d692c25c47d05b = function(arg0) {
|
|
582
|
+
const ret = getObject(arg0).queueMicrotask;
|
|
583
|
+
return addHeapObject(ret);
|
|
584
|
+
};
|
|
585
|
+
imports.wbg.__wbg_queueMicrotask_9d76cacb20c84d58 = function(arg0) {
|
|
586
|
+
queueMicrotask(getObject(arg0));
|
|
587
|
+
};
|
|
588
|
+
imports.wbg.__wbg_resolve_caf97c30b83f7053 = function(arg0) {
|
|
589
|
+
const ret = Promise.resolve(getObject(arg0));
|
|
590
|
+
return addHeapObject(ret);
|
|
591
|
+
};
|
|
452
592
|
imports.wbg.__wbg_set_3f1d0b984ed272ed = function(arg0, arg1, arg2) {
|
|
453
593
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
454
594
|
};
|
|
455
|
-
imports.wbg.
|
|
595
|
+
imports.wbg.__wbg_set_c213c871859d6500 = function(arg0, arg1, arg2) {
|
|
456
596
|
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
457
597
|
};
|
|
458
|
-
imports.wbg.
|
|
459
|
-
const
|
|
460
|
-
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
461
|
-
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
462
|
-
};
|
|
463
|
-
imports.wbg.__wbg_wbindgendebugstring_99ef257a3ddda34d = function(arg0, arg1) {
|
|
464
|
-
const ret = debugString(getObject(arg1));
|
|
465
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
466
|
-
const len1 = WASM_VECTOR_LEN;
|
|
467
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
468
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
469
|
-
};
|
|
470
|
-
imports.wbg.__wbg_wbindgenin_d7a1ee10933d2d55 = function(arg0, arg1) {
|
|
471
|
-
const ret = getObject(arg0) in getObject(arg1);
|
|
598
|
+
imports.wbg.__wbg_size_0a5a003dbf5dfee8 = function(arg0) {
|
|
599
|
+
const ret = getObject(arg0).size;
|
|
472
600
|
return ret;
|
|
473
601
|
};
|
|
474
|
-
imports.wbg.
|
|
475
|
-
const
|
|
476
|
-
|
|
477
|
-
return ret;
|
|
602
|
+
imports.wbg.__wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e = function() {
|
|
603
|
+
const ret = typeof global === 'undefined' ? null : global;
|
|
604
|
+
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
478
605
|
};
|
|
479
|
-
imports.wbg.
|
|
480
|
-
const ret = typeof
|
|
481
|
-
return ret;
|
|
606
|
+
imports.wbg.__wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac = function() {
|
|
607
|
+
const ret = typeof globalThis === 'undefined' ? null : globalThis;
|
|
608
|
+
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
482
609
|
};
|
|
483
|
-
imports.wbg.
|
|
484
|
-
const ret =
|
|
485
|
-
return ret;
|
|
610
|
+
imports.wbg.__wbg_static_accessor_SELF_6fdf4b64710cc91b = function() {
|
|
611
|
+
const ret = typeof self === 'undefined' ? null : self;
|
|
612
|
+
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
486
613
|
};
|
|
487
|
-
imports.wbg.
|
|
488
|
-
const ret =
|
|
489
|
-
return ret;
|
|
614
|
+
imports.wbg.__wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2 = function() {
|
|
615
|
+
const ret = typeof window === 'undefined' ? null : window;
|
|
616
|
+
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
490
617
|
};
|
|
491
|
-
imports.wbg.
|
|
492
|
-
const
|
|
493
|
-
|
|
494
|
-
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
495
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
618
|
+
imports.wbg.__wbg_storage_3e7b84b6fbb9dd1c = function(arg0) {
|
|
619
|
+
const ret = getObject(arg0).storage;
|
|
620
|
+
return addHeapObject(ret);
|
|
496
621
|
};
|
|
497
|
-
imports.wbg.
|
|
498
|
-
const
|
|
499
|
-
|
|
500
|
-
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
501
|
-
var len1 = WASM_VECTOR_LEN;
|
|
502
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
503
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
622
|
+
imports.wbg.__wbg_then_4f46f6544e6b4a28 = function(arg0, arg1) {
|
|
623
|
+
const ret = getObject(arg0).then(getObject(arg1));
|
|
624
|
+
return addHeapObject(ret);
|
|
504
625
|
};
|
|
505
|
-
imports.wbg.
|
|
506
|
-
|
|
626
|
+
imports.wbg.__wbg_then_70d05cf780a18d77 = function(arg0, arg1, arg2) {
|
|
627
|
+
const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));
|
|
628
|
+
return addHeapObject(ret);
|
|
629
|
+
};
|
|
630
|
+
imports.wbg.__wbg_value_692627309814bb8c = function(arg0) {
|
|
631
|
+
const ret = getObject(arg0).value;
|
|
632
|
+
return addHeapObject(ret);
|
|
507
633
|
};
|
|
508
634
|
imports.wbg.__wbindgen_cast_2241b6af4c4b2941 = function(arg0, arg1) {
|
|
509
635
|
// Cast intrinsic for `Ref(String) -> Externref`.
|
|
@@ -515,6 +641,11 @@ function __wbg_get_imports() {
|
|
|
515
641
|
const ret = arg0;
|
|
516
642
|
return addHeapObject(ret);
|
|
517
643
|
};
|
|
644
|
+
imports.wbg.__wbindgen_cast_fd0586cfe4f12dd7 = function(arg0, arg1) {
|
|
645
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 258, function: Function { arguments: [Externref], shim_idx: 259, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
646
|
+
const ret = makeMutClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_2760, __wasm_bindgen_func_elem_2761);
|
|
647
|
+
return addHeapObject(ret);
|
|
648
|
+
};
|
|
518
649
|
imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
|
|
519
650
|
const ret = getObject(arg0);
|
|
520
651
|
return addHeapObject(ret);
|
|
@@ -526,10 +657,6 @@ function __wbg_get_imports() {
|
|
|
526
657
|
return imports;
|
|
527
658
|
}
|
|
528
659
|
|
|
529
|
-
function __wbg_init_memory(imports, memory) {
|
|
530
|
-
|
|
531
|
-
}
|
|
532
|
-
|
|
533
660
|
function __wbg_finalize_init(instance, module) {
|
|
534
661
|
wasm = instance.exports;
|
|
535
662
|
__wbg_init.__wbindgen_wasm_module = module;
|
|
@@ -555,8 +682,6 @@ function initSync(module) {
|
|
|
555
682
|
|
|
556
683
|
const imports = __wbg_get_imports();
|
|
557
684
|
|
|
558
|
-
__wbg_init_memory(imports);
|
|
559
|
-
|
|
560
685
|
if (!(module instanceof WebAssembly.Module)) {
|
|
561
686
|
module = new WebAssembly.Module(module);
|
|
562
687
|
}
|
|
@@ -587,8 +712,6 @@ async function __wbg_init(module_or_path) {
|
|
|
587
712
|
module_or_path = fetch(module_or_path);
|
|
588
713
|
}
|
|
589
714
|
|
|
590
|
-
__wbg_init_memory(imports);
|
|
591
|
-
|
|
592
715
|
const { instance, module } = await __wbg_load(await module_or_path, imports);
|
|
593
716
|
|
|
594
717
|
return __wbg_finalize_init(instance, module);
|
package/dist/mq_wasm_bg.wasm
CHANGED
|
Binary file
|