import{e as $,_ as G,r as T,a as k,s as C,t as j,u as D}from"./es-errors-DzOT6E3C.1735711566000.js";import{g as M}from"./gopd-fcd2-aIC.1735711566000.js";import{e as W}from"./es-define-property-bDCdrV83.1735711566000.js";import{r as q}from"./has-symbols-BaUvM3gb.1735711566000.js";import{r as J}from"./dunder-proto-0l1vuzli.1735711566000.js";import{r as V,b as z}from"./call-bind-apply-helpers-0RM3uiXS.1735711566000.js";import{r as H}from"./function-bind-CHqF18-c.1735711566000.js";import{r as L}from"./hasown-DByPsmSW.1735711566000.js";var r,Y=$,K=G,Q=T,X=k,d=C,A=j,Z=D,N=Function,w=function(i){try{return N('"use strict"; return ('+i+").constructor;")()}catch{}},v=M,rr=W,B=function(){throw new A},er=v?function(){try{return arguments.callee,B}catch{try{return v(arguments,"callee").get}catch{return B}}}():B,l=q()(),tr=J(),o=typeof Reflect=="function"&&Reflect.getPrototypeOf||Object.getPrototypeOf||tr,_=V(),g=z(),u={},or=typeof Uint8Array>"u"||!o?r:o(Uint8Array),s={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":l&&o?o([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":u,"%AsyncGenerator%":u,"%AsyncGeneratorFunction%":u,"%AsyncIteratorPrototype%":u,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?r:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Y,"%eval%":eval,"%EvalError%":K,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":N,"%GeneratorFunction%":u,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":l&&o?o(o([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!l||!o?r:o(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%Object.getOwnPropertyDescriptor%":v,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":Q,"%ReferenceError%":X,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!l||!o?r:o(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":l&&o?o(""[Symbol.iterator]()):r,"%Symbol%":l?Symbol:r,"%SyntaxError%":d,"%ThrowTypeError%":er,"%TypedArray%":or,"%TypeError%":A,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":Z,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet,"%Function.prototype.call%":g,"%Function.prototype.apply%":_,"%Object.defineProperty%":rr};if(o)try{null.error}catch(i){var nr=o(o(i));s["%Error.prototype%"]=nr}var ar=function i(e){var n;if(e==="%AsyncFunction%")n=w("async function () {}");else if(e==="%GeneratorFunction%")n=w("function* () {}");else if(e==="%AsyncGeneratorFunction%")n=w("async function* () {}");else if(e==="%AsyncGenerator%"){var t=i("%AsyncGeneratorFunction%");t&&(n=t.prototype)}else if(e==="%AsyncIteratorPrototype%"){var a=i("%AsyncGenerator%");a&&o&&(n=o(a.prototype))}return s[e]=n,n},x={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=H(),b=L(),yr=m.call(g,Array.prototype.concat),ir=m.call(_,Array.prototype.splice),O=m.call(g,String.prototype.replace),R=m.call(g,String.prototype.slice),pr=m.call(g,RegExp.prototype.exec),fr=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,sr=/\\(\\)?/g,cr=function(e){var n=R(e,0,1),t=R(e,-1);if(n==="%"&&t!=="%")throw new d("invalid intrinsic syntax, expected closing `%`");if(t==="%"&&n!=="%")throw new d("invalid intrinsic syntax, expected opening `%`");var a=[];return O(e,fr,function(p,c,y,S){a[a.length]=y?O(S,sr,"$1"):c||p}),a},lr=function(e,n){var t=e,a;if(b(x,t)&&(a=x[t],t="%"+a[0]+"%"),b(s,t)){var p=s[t];if(p===u&&(p=ar(t)),typeof p>"u"&&!n)throw new A("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:a,name:t,value:p}}throw new d("intrinsic "+e+" does not exist!")},Er=function(e,n){if(typeof e!="string"||e.length===0)throw new A("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof n!="boolean")throw new A('"allowMissing" argument must be a boolean');if(pr(/^%?[^%]*%?$/,e)===null)throw new d("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var t=cr(e),a=t.length>0?t[0]:"",p=lr("%"+a+"%",n),c=p.name,y=p.value,S=!1,U=p.alias;U&&(a=U[0],ir(t,yr([0,1],U)));for(var E=1,P=!0;E=t.length){var F=v(y,f);P=!!F,P&&"get"in F&&!("originalValue"in F.get)?y=F.get:y=y[f]}else P=b(y,f),y=y[f];P&&!S&&(s[c]=y)}}return y};export{Er as g};