aboutsummaryrefslogtreecommitdiff
path: root/src/js/out/WebCoreJSBuiltins.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/js/out/WebCoreJSBuiltins.cpp')
-rw-r--r--src/js/out/WebCoreJSBuiltins.cpp116
1 files changed, 58 insertions, 58 deletions
diff --git a/src/js/out/WebCoreJSBuiltins.cpp b/src/js/out/WebCoreJSBuiltins.cpp
index 1da79e02c..f744eb3b2 100644
--- a/src/js/out/WebCoreJSBuiltins.cpp
+++ b/src/js/out/WebCoreJSBuiltins.cpp
@@ -116,7 +116,7 @@ const JSC::ConstructorKind s_writableStreamInternalsCreateInternalWritableStream
const JSC::ImplementationVisibility s_writableStreamInternalsCreateInternalWritableStreamFromUnderlyingSinkCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_writableStreamInternalsCreateInternalWritableStreamFromUnderlyingSinkCodeLength = 956;
static const JSC::Intrinsic s_writableStreamInternalsCreateInternalWritableStreamFromUnderlyingSinkCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_writableStreamInternalsCreateInternalWritableStreamFromUnderlyingSinkCode = "(function (f,o){\"use strict\";const w={};if(f===@undefined)f={};if(o===@undefined)o={};if(!@isObject(f))@throwTypeError(\"WritableStream constructor takes an object as first argument\");if(\"type\"in f)@throwRangeError(\"Invalid type is specified\");const C=@extractSizeAlgorithm(o),E=@extractHighWaterMark(o,1),_={};if(\"start\"in f){if(_[\"start\"]=f[\"start\"],typeof _[\"start\"]!==\"function\")@throwTypeError(\"underlyingSink.start should be a function\")}if(\"write\"in f){if(_[\"write\"]=f[\"write\"],typeof _[\"write\"]!==\"function\")@throwTypeError(\"underlyingSink.write should be a function\")}if(\"close\"in f){if(_[\"close\"]=f[\"close\"],typeof _[\"close\"]!==\"function\")@throwTypeError(\"underlyingSink.close should be a function\")}if(\"abort\"in f){if(_[\"abort\"]=f[\"abort\"],typeof _[\"abort\"]!==\"function\")@throwTypeError(\"underlyingSink.abort should be a function\")}return @initializeWritableStreamSlots(w,f),@setUpWritableStreamDefaultControllerFromUnderlyingSink(w,f,_,E,C),w})\n";
+const char* const s_writableStreamInternalsCreateInternalWritableStreamFromUnderlyingSinkCode = "(function (o,w){\"use strict\";const C={};if(o===@undefined)o={};if(w===@undefined)w={};if(!@isObject(o))@throwTypeError(\"WritableStream constructor takes an object as first argument\");if(\"type\"in o)@throwRangeError(\"Invalid type is specified\");const E=@extractSizeAlgorithm(w),_=@extractHighWaterMark(w,1),f={};if(\"start\"in o){if(f[\"start\"]=o[\"start\"],typeof f[\"start\"]!==\"function\")@throwTypeError(\"underlyingSink.start should be a function\")}if(\"write\"in o){if(f[\"write\"]=o[\"write\"],typeof f[\"write\"]!==\"function\")@throwTypeError(\"underlyingSink.write should be a function\")}if(\"close\"in o){if(f[\"close\"]=o[\"close\"],typeof f[\"close\"]!==\"function\")@throwTypeError(\"underlyingSink.close should be a function\")}if(\"abort\"in o){if(f[\"abort\"]=o[\"abort\"],typeof f[\"abort\"]!==\"function\")@throwTypeError(\"underlyingSink.abort should be a function\")}return @initializeWritableStreamSlots(C,o),@setUpWritableStreamDefaultControllerFromUnderlyingSink(C,o,f,_,E),C})\n";
// initializeWritableStreamSlots
const JSC::ConstructAbility s_writableStreamInternalsInitializeWritableStreamSlotsCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -156,7 +156,7 @@ const JSC::ConstructorKind s_writableStreamInternalsSetUpWritableStreamDefaultWr
const JSC::ImplementationVisibility s_writableStreamInternalsSetUpWritableStreamDefaultWriterCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_writableStreamInternalsSetUpWritableStreamDefaultWriterCodeLength = 887;
static const JSC::Intrinsic s_writableStreamInternalsSetUpWritableStreamDefaultWriterCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_writableStreamInternalsSetUpWritableStreamDefaultWriterCode = "(function (n,v){\"use strict\";if(@isWritableStreamLocked(v))@throwTypeError(\"WritableStream is locked\");@putByIdDirectPrivate(n,\"stream\",v),@putByIdDirectPrivate(v,\"writer\",n);const g=@newPromiseCapability(@Promise),h=@newPromiseCapability(@Promise);@putByIdDirectPrivate(n,\"readyPromise\",g),@putByIdDirectPrivate(n,\"closedPromise\",h);const B=@getByIdDirectPrivate(v,\"state\");if(B===\"writable\"){if(@writableStreamCloseQueuedOrInFlight(v)||!@getByIdDirectPrivate(v,\"backpressure\"))g.@resolve.@call()}else if(B===\"erroring\")g.@reject.@call(@undefined,@getByIdDirectPrivate(v,\"storedError\")),@markPromiseAsHandled(g.@promise);else if(B===\"closed\")g.@resolve.@call(),h.@resolve.@call();else{@assert(B===\"errored\");const _=@getByIdDirectPrivate(v,\"storedError\");g.@reject.@call(@undefined,_),@markPromiseAsHandled(g.@promise),h.@reject.@call(@undefined,_),@markPromiseAsHandled(h.@promise)}})\n";
+const char* const s_writableStreamInternalsSetUpWritableStreamDefaultWriterCode = "(function (v,B){\"use strict\";if(@isWritableStreamLocked(B))@throwTypeError(\"WritableStream is locked\");@putByIdDirectPrivate(v,\"stream\",B),@putByIdDirectPrivate(B,\"writer\",v);const n=@newPromiseCapability(@Promise),h=@newPromiseCapability(@Promise);@putByIdDirectPrivate(v,\"readyPromise\",n),@putByIdDirectPrivate(v,\"closedPromise\",h);const _=@getByIdDirectPrivate(B,\"state\");if(_===\"writable\"){if(@writableStreamCloseQueuedOrInFlight(B)||!@getByIdDirectPrivate(B,\"backpressure\"))n.@resolve.@call()}else if(_===\"erroring\")n.@reject.@call(@undefined,@getByIdDirectPrivate(B,\"storedError\")),@markPromiseAsHandled(n.@promise);else if(_===\"closed\")n.@resolve.@call(),h.@resolve.@call();else{@assert(_===\"errored\");const g=@getByIdDirectPrivate(B,\"storedError\");n.@reject.@call(@undefined,g),@markPromiseAsHandled(n.@promise),h.@reject.@call(@undefined,g),@markPromiseAsHandled(h.@promise)}})\n";
// writableStreamAbort
const JSC::ConstructAbility s_writableStreamInternalsWritableStreamAbortCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -236,7 +236,7 @@ const JSC::ConstructorKind s_writableStreamInternalsWritableStreamFinishInFlight
const JSC::ImplementationVisibility s_writableStreamInternalsWritableStreamFinishInFlightWriteWithErrorCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_writableStreamInternalsWritableStreamFinishInFlightWriteWithErrorCodeLength = 319;
static const JSC::Intrinsic s_writableStreamInternalsWritableStreamFinishInFlightWriteWithErrorCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_writableStreamInternalsWritableStreamFinishInFlightWriteWithErrorCode = "(function (_,p){\"use strict\";const d=@getByIdDirectPrivate(_,\"inFlightWriteRequest\");@assert(d!==@undefined),d.@reject.@call(@undefined,p),@putByIdDirectPrivate(_,\"inFlightWriteRequest\",@undefined);const c=@getByIdDirectPrivate(_,\"state\");@assert(c===\"writable\"||c===\"erroring\"),@writableStreamDealWithRejection(_,p)})\n";
+const char* const s_writableStreamInternalsWritableStreamFinishInFlightWriteWithErrorCode = "(function (_,c){\"use strict\";const d=@getByIdDirectPrivate(_,\"inFlightWriteRequest\");@assert(d!==@undefined),d.@reject.@call(@undefined,c),@putByIdDirectPrivate(_,\"inFlightWriteRequest\",@undefined);const p=@getByIdDirectPrivate(_,\"state\");@assert(p===\"writable\"||p===\"erroring\"),@writableStreamDealWithRejection(_,c)})\n";
// writableStreamHasOperationMarkedInFlight
const JSC::ConstructAbility s_writableStreamInternalsWritableStreamHasOperationMarkedInFlightCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -468,7 +468,7 @@ const JSC::ConstructorKind s_writableStreamInternalsWritableStreamDefaultControl
const JSC::ImplementationVisibility s_writableStreamInternalsWritableStreamDefaultControllerWriteCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_writableStreamInternalsWritableStreamDefaultControllerWriteCodeLength = 450;
static const JSC::Intrinsic s_writableStreamInternalsWritableStreamDefaultControllerWriteCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_writableStreamInternalsWritableStreamDefaultControllerWriteCode = "(function (y,B,D){\"use strict\";try{@enqueueValueWithSize(@getByIdDirectPrivate(y,\"queue\"),B,D);const I=@getByIdDirectPrivate(y,\"stream\"),_=@getByIdDirectPrivate(I,\"state\");if(!@writableStreamCloseQueuedOrInFlight(I)&&_===\"writable\"){const d=@writableStreamDefaultControllerGetBackpressure(y);@writableStreamUpdateBackpressure(I,d)}@writableStreamDefaultControllerAdvanceQueueIfNeeded(y)}catch(I){@writableStreamDefaultControllerErrorIfNeeded(y,I)}})\n";
+const char* const s_writableStreamInternalsWritableStreamDefaultControllerWriteCode = "(function (d,y,B){\"use strict\";try{@enqueueValueWithSize(@getByIdDirectPrivate(d,\"queue\"),y,B);const D=@getByIdDirectPrivate(d,\"stream\"),I=@getByIdDirectPrivate(D,\"state\");if(!@writableStreamCloseQueuedOrInFlight(D)&&I===\"writable\"){const _=@writableStreamDefaultControllerGetBackpressure(d);@writableStreamUpdateBackpressure(D,_)}@writableStreamDefaultControllerAdvanceQueueIfNeeded(d)}catch(D){@writableStreamDefaultControllerErrorIfNeeded(d,D)}})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \
@@ -502,7 +502,7 @@ const JSC::ConstructorKind s_transformStreamInternalsCreateTransformStreamCodeCo
const JSC::ImplementationVisibility s_transformStreamInternalsCreateTransformStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsCreateTransformStreamCodeLength = 513;
static const JSC::Intrinsic s_transformStreamInternalsCreateTransformStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsCreateTransformStreamCode = "(function (j,q,v,x,B,D,E){\"use strict\";if(x===@undefined)x=1;if(B===@undefined)B=()=>1;if(D===@undefined)D=0;if(E===@undefined)E=()=>1;@assert(x>=0),@assert(D>=0);const F={};@putByIdDirectPrivate(F,\"TransformStream\",!0);const G=new @TransformStream(F),I=@newPromiseCapability(@Promise);@initializeTransformStream(G,I.@promise,x,B,D,E);const _=new @TransformStreamDefaultController;return @setUpTransformStreamDefaultController(G,_,q,v),j().@then(()=>{I.@resolve.@call()},(c)=>{I.@reject.@call(@undefined,c)}),G})\n";
+const char* const s_transformStreamInternalsCreateTransformStreamCode = "(function (c,x,B,D,E,F,G){\"use strict\";if(D===@undefined)D=1;if(E===@undefined)E=()=>1;if(F===@undefined)F=0;if(G===@undefined)G=()=>1;@assert(D>=0),@assert(F>=0);const I={};@putByIdDirectPrivate(I,\"TransformStream\",!0);const j=new @TransformStream(I),q=@newPromiseCapability(@Promise);@initializeTransformStream(j,q.@promise,D,E,F,G);const _=new @TransformStreamDefaultController;return @setUpTransformStreamDefaultController(j,_,x,B),c().@then(()=>{q.@resolve.@call()},(v)=>{q.@reject.@call(@undefined,v)}),j})\n";
// initializeTransformStream
const JSC::ConstructAbility s_transformStreamInternalsInitializeTransformStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -510,7 +510,7 @@ const JSC::ConstructorKind s_transformStreamInternalsInitializeTransformStreamCo
const JSC::ImplementationVisibility s_transformStreamInternalsInitializeTransformStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsInitializeTransformStreamCodeLength = 1015;
static const JSC::Intrinsic s_transformStreamInternalsInitializeTransformStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsInitializeTransformStreamCode = "(function (T,j,v,C,D,E){\"use strict\";const F=()=>{return j},G=(N)=>{return @transformStreamDefaultSinkWriteAlgorithm(T,N)},I=(N)=>{return @transformStreamDefaultSinkAbortAlgorithm(T,N)},J=()=>{return @transformStreamDefaultSinkCloseAlgorithm(T)},f=@createWritableStream(F,G,J,I,v,C),B=()=>{return @transformStreamDefaultSourcePullAlgorithm(T)},q=(N)=>{return @transformStreamErrorWritableAndUnblockWrite(T,N),@Promise.@resolve()},x={};@putByIdDirectPrivate(x,\"start\",F),@putByIdDirectPrivate(x,\"pull\",B),@putByIdDirectPrivate(x,\"cancel\",q);const K={};@putByIdDirectPrivate(K,\"size\",E),@putByIdDirectPrivate(K,\"highWaterMark\",D);const L=new @ReadableStream(x,K);@putByIdDirectPrivate(T,\"writable\",f),@putByIdDirectPrivate(T,\"internalWritable\",@getInternalWritableStream(f)),@putByIdDirectPrivate(T,\"readable\",L),@putByIdDirectPrivate(T,\"backpressure\",@undefined),@putByIdDirectPrivate(T,\"backpressureChangePromise\",@undefined),@transformStreamSetBackpressure(T,!0),@putByIdDirectPrivate(T,\"controller\",@undefined)})\n";
+const char* const s_transformStreamInternalsInitializeTransformStreamCode = "(function (B,T,j,I,q,J){\"use strict\";const v=()=>{return T},K=(F)=>{return @transformStreamDefaultSinkWriteAlgorithm(B,F)},x=(F)=>{return @transformStreamDefaultSinkAbortAlgorithm(B,F)},L=()=>{return @transformStreamDefaultSinkCloseAlgorithm(B)},C=@createWritableStream(v,K,L,x,j,I),f=()=>{return @transformStreamDefaultSourcePullAlgorithm(B)},D=(F)=>{return @transformStreamErrorWritableAndUnblockWrite(B,F),@Promise.@resolve()},G={};@putByIdDirectPrivate(G,\"start\",v),@putByIdDirectPrivate(G,\"pull\",f),@putByIdDirectPrivate(G,\"cancel\",D);const E={};@putByIdDirectPrivate(E,\"size\",J),@putByIdDirectPrivate(E,\"highWaterMark\",q);const N=new @ReadableStream(G,E);@putByIdDirectPrivate(B,\"writable\",C),@putByIdDirectPrivate(B,\"internalWritable\",@getInternalWritableStream(C)),@putByIdDirectPrivate(B,\"readable\",N),@putByIdDirectPrivate(B,\"backpressure\",@undefined),@putByIdDirectPrivate(B,\"backpressureChangePromise\",@undefined),@transformStreamSetBackpressure(B,!0),@putByIdDirectPrivate(B,\"controller\",@undefined)})\n";
// transformStreamError
const JSC::ConstructAbility s_transformStreamInternalsTransformStreamErrorCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -550,7 +550,7 @@ const JSC::ConstructorKind s_transformStreamInternalsSetUpTransformStreamDefault
const JSC::ImplementationVisibility s_transformStreamInternalsSetUpTransformStreamDefaultControllerFromTransformerCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsSetUpTransformStreamDefaultControllerFromTransformerCodeLength = 449;
static const JSC::Intrinsic s_transformStreamInternalsSetUpTransformStreamDefaultControllerFromTransformerCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsSetUpTransformStreamDefaultControllerFromTransformerCode = "(function (_,d,p){\"use strict\";const v=new @TransformStreamDefaultController;let b=(q)=>{try{@transformStreamDefaultControllerEnqueue(v,q)}catch(w){return @Promise.@reject(w)}return @Promise.@resolve()},j=()=>{return @Promise.@resolve()};if(\"transform\"in p)b=(q)=>{return @promiseInvokeOrNoopMethod(d,p[\"transform\"],[q,v])};if(\"flush\"in p)j=()=>{return @promiseInvokeOrNoopMethod(d,p[\"flush\"],[v])};@setUpTransformStreamDefaultController(_,v,b,j)})\n";
+const char* const s_transformStreamInternalsSetUpTransformStreamDefaultControllerFromTransformerCode = "(function (d,p,v){\"use strict\";const b=new @TransformStreamDefaultController;let q=(j)=>{try{@transformStreamDefaultControllerEnqueue(b,j)}catch(w){return @Promise.@reject(w)}return @Promise.@resolve()},_=()=>{return @Promise.@resolve()};if(\"transform\"in v)q=(j)=>{return @promiseInvokeOrNoopMethod(p,v[\"transform\"],[j,b])};if(\"flush\"in v)_=()=>{return @promiseInvokeOrNoopMethod(p,v[\"flush\"],[b])};@setUpTransformStreamDefaultController(d,b,q,_)})\n";
// transformStreamDefaultControllerClearAlgorithms
const JSC::ConstructAbility s_transformStreamInternalsTransformStreamDefaultControllerClearAlgorithmsCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -566,7 +566,7 @@ const JSC::ConstructorKind s_transformStreamInternalsTransformStreamDefaultContr
const JSC::ImplementationVisibility s_transformStreamInternalsTransformStreamDefaultControllerEnqueueCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsTransformStreamDefaultControllerEnqueueCodeLength = 622;
static const JSC::Intrinsic s_transformStreamInternalsTransformStreamDefaultControllerEnqueueCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsTransformStreamDefaultControllerEnqueueCode = "(function (_,S){\"use strict\";const W=@getByIdDirectPrivate(_,\"stream\"),f=@getByIdDirectPrivate(W,\"readable\"),g=@getByIdDirectPrivate(f,\"readableStreamController\");if(@assert(g!==@undefined),!@readableStreamDefaultControllerCanCloseOrEnqueue(g))@throwTypeError(\"TransformStream.readable cannot close or enqueue\");try{@readableStreamDefaultControllerEnqueue(g,S)}catch(j){throw @transformStreamErrorWritableAndUnblockWrite(W,j),@getByIdDirectPrivate(f,\"storedError\")}const i=!@readableStreamDefaultControllerShouldCallPull(g);if(i!==@getByIdDirectPrivate(W,\"backpressure\"))@assert(i),@transformStreamSetBackpressure(W,!0)})\n";
+const char* const s_transformStreamInternalsTransformStreamDefaultControllerEnqueueCode = "(function (S,W){\"use strict\";const f=@getByIdDirectPrivate(S,\"stream\"),g=@getByIdDirectPrivate(f,\"readable\"),j=@getByIdDirectPrivate(g,\"readableStreamController\");if(@assert(j!==@undefined),!@readableStreamDefaultControllerCanCloseOrEnqueue(j))@throwTypeError(\"TransformStream.readable cannot close or enqueue\");try{@readableStreamDefaultControllerEnqueue(j,W)}catch(i){throw @transformStreamErrorWritableAndUnblockWrite(f,i),@getByIdDirectPrivate(g,\"storedError\")}const _=!@readableStreamDefaultControllerShouldCallPull(j);if(_!==@getByIdDirectPrivate(f,\"backpressure\"))@assert(_),@transformStreamSetBackpressure(f,!0)})\n";
// transformStreamDefaultControllerError
const JSC::ConstructAbility s_transformStreamInternalsTransformStreamDefaultControllerErrorCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -598,7 +598,7 @@ const JSC::ConstructorKind s_transformStreamInternalsTransformStreamDefaultSinkW
const JSC::ImplementationVisibility s_transformStreamInternalsTransformStreamDefaultSinkWriteAlgorithmCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsTransformStreamDefaultSinkWriteAlgorithmCodeLength = 764;
static const JSC::Intrinsic s_transformStreamInternalsTransformStreamDefaultSinkWriteAlgorithmCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsTransformStreamDefaultSinkWriteAlgorithmCode = "(function (_,d){\"use strict\";const v=@getByIdDirectPrivate(_,\"internalWritable\");@assert(@getByIdDirectPrivate(v,\"state\")===\"writable\");const f=@getByIdDirectPrivate(_,\"controller\");if(@getByIdDirectPrivate(_,\"backpressure\")){const j=@newPromiseCapability(@Promise),q=@getByIdDirectPrivate(_,\"backpressureChangePromise\");return @assert(q!==@undefined),q.@promise.@then(()=>{const x=@getByIdDirectPrivate(v,\"state\");if(x===\"erroring\"){j.@reject.@call(@undefined,@getByIdDirectPrivate(v,\"storedError\"));return}@assert(x===\"writable\"),@transformStreamDefaultControllerPerformTransform(f,d).@then(()=>{j.@resolve()},(z)=>{j.@reject.@call(@undefined,z)})},(x)=>{j.@reject.@call(@undefined,x)}),j.@promise}return @transformStreamDefaultControllerPerformTransform(f,d)})\n";
+const char* const s_transformStreamInternalsTransformStreamDefaultSinkWriteAlgorithmCode = "(function (d,v){\"use strict\";const f=@getByIdDirectPrivate(d,\"internalWritable\");@assert(@getByIdDirectPrivate(f,\"state\")===\"writable\");const j=@getByIdDirectPrivate(d,\"controller\");if(@getByIdDirectPrivate(d,\"backpressure\")){const x=@newPromiseCapability(@Promise),_=@getByIdDirectPrivate(d,\"backpressureChangePromise\");return @assert(_!==@undefined),_.@promise.@then(()=>{const q=@getByIdDirectPrivate(f,\"state\");if(q===\"erroring\"){x.@reject.@call(@undefined,@getByIdDirectPrivate(f,\"storedError\"));return}@assert(q===\"writable\"),@transformStreamDefaultControllerPerformTransform(j,v).@then(()=>{x.@resolve()},(z)=>{x.@reject.@call(@undefined,z)})},(q)=>{x.@reject.@call(@undefined,q)}),x.@promise}return @transformStreamDefaultControllerPerformTransform(j,v)})\n";
// transformStreamDefaultSinkAbortAlgorithm
const JSC::ConstructAbility s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -606,7 +606,7 @@ const JSC::ConstructorKind s_transformStreamInternalsTransformStreamDefaultSinkA
const JSC::ImplementationVisibility s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCodeLength = 85;
static const JSC::Intrinsic s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCode = "(function (t,d){\"use strict\";return @transformStreamError(t,d),@Promise.@resolve()})\n";
+const char* const s_transformStreamInternalsTransformStreamDefaultSinkAbortAlgorithmCode = "(function (d,t){\"use strict\";return @transformStreamError(d,t),@Promise.@resolve()})\n";
// transformStreamDefaultSinkCloseAlgorithm
const JSC::ConstructAbility s_transformStreamInternalsTransformStreamDefaultSinkCloseAlgorithmCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -648,7 +648,7 @@ const JSC::ConstructorKind s_processObjectInternalsGetStdioWriteStreamCodeConstr
const JSC::ImplementationVisibility s_processObjectInternalsGetStdioWriteStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_processObjectInternalsGetStdioWriteStreamCodeLength = 4250;
static const JSC::Intrinsic s_processObjectInternalsGetStdioWriteStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_processObjectInternalsGetStdioWriteStreamCode = "(function (j,z){\"use strict\";var L={path:\"node:process\",require:z},K=(N)=>L.require(N);function G(N){var{Duplex:O,eos:Q,destroy:U}=K(\"node:stream\"),V=class X extends O{#$;#B;#j=!0;#z=!0;#G;#H;#J;#K;#L;#M;get isTTY(){return this.#M\?\?=K(\"node:tty\").isatty(N)}get fd(){return N}constructor(Z){super({readable:!0,writable:!0});this.#G=`/dev/fd/${Z}`}#N(Z){const Y=this.#H;if(this.#H=null,Y)Y(Z);else if(Z)this.destroy(Z);else if(!this.#j&&!this.#z)this.destroy()}_destroy(Z,Y){if(!Z&&this.#H!==null){var P=class A extends Error{code;name;constructor(T=\"The operation was aborted\",x=void 0){if(x!==void 0&&typeof x!==\"object\")throw new Error(`Invalid AbortError options:\\n\\n${JSON.stringify(x,null,2)}`);super(T,x);this.code=\"ABORT_ERR\",this.name=\"AbortError\"}};Z=new P}if(this.#J=null,this.#K=null,this.#H===null)Y(Z);else{if(this.#H=Y,this.#$)U(this.#$,Z);if(this.#B)U(this.#B,Z)}}_write(Z,Y,P){if(!this.#$){var{createWriteStream:A}=K(\"node:fs\"),T=this.#$=A(this.#G);T.on(\"finish\",()=>{if(this.#K){const x=this.#K;this.#K=null,x()}}),T.on(\"drain\",()=>{if(this.#J){const x=this.#J;this.#J=null,x()}}),Q(T,(x)=>{if(this.#z=!1,x)U(T,x);this.#N(x)})}if(T.write(Z,Y))P();else this.#J=P}_final(Z){this.#$&&this.#$.end(),this.#K=Z}#O(){var{createReadStream:Z}=K(\"node:fs\"),Y=this.#B=Z(this.#G);return Y.on(\"readable\",()=>{if(this.#L){const P=this.#L;this.#L=null,P()}else this.read()}),Y.on(\"end\",()=>{this.push(null)}),Q(Y,(P)=>{if(this.#j=!1,P)U(Y,P);this.#N(P)}),Y}_read(){var Z=this.#B;if(!Z)Z=this.#O();while(!0){const Y=Z.read();if(Y===null||!this.push(Y))return}}};return new V(N)}var{EventEmitter:H}=K(\"node:events\");function M(N){if(!N)return!0;var O=N.toLowerCase();return O===\"utf8\"||O===\"utf-8\"||O===\"buffer\"||O===\"binary\"}var J,B=class N extends H{#$;#B;#j;#z;bytesWritten=0;setDefaultEncoding(O){if(this.#B||!M(O))return this.#J(),this.#B.setDefaultEncoding(O)}#G(){switch(this.#$){case 1:{var O=@Bun.stdout.writer({highWaterMark:0});return O.unref(),O}case 2:{var O=@Bun.stderr.writer({highWaterMark:0});return O.unref(),O}default:throw new Error(\"Unsupported writer\")}}#H(){return this.#j\?\?=this.#G()}constructor(O){super();this.#$=O}get fd(){return this.#$}get isTTY(){return this.#z\?\?=K(\"node:tty\").isatty(this.#$)}cursorTo(O,Q,U){return(J\?\?=K(\"readline\")).cursorTo(this,O,Q,U)}moveCursor(O,Q,U){return(J\?\?=K(\"readline\")).moveCursor(this,O,Q,U)}clearLine(O,Q){return(J\?\?=K(\"readline\")).clearLine(this,O,Q)}clearScreenDown(O){return(J\?\?=K(\"readline\")).clearScreenDown(this,O)}ref(){this.#H().ref()}unref(){this.#H().unref()}on(O,Q){if(O===\"close\"||O===\"finish\")return this.#J(),this.#B.on(O,Q);if(O===\"drain\")return super.on(\"drain\",Q);if(O===\"error\")return super.on(\"error\",Q);return super.on(O,Q)}get _writableState(){return this.#J(),this.#B._writableState}get _readableState(){return this.#J(),this.#B._readableState}pipe(O){return this.#J(),this.#B.pipe(O)}unpipe(O){return this.#J(),this.#B.unpipe(O)}#J(){if(this.#B)return;this.#B=G(this.#$);const O=this.eventNames();for(let Q of O)this.#B.on(Q,(...U)=>{this.emit(Q,...U)})}#K(O){var Q=this.#H();const U=Q.write(O);this.bytesWritten+=U;const V=Q.flush(!1);return!!(U||V)}#L(O,Q){if(!M(Q))return this.#J(),this.#B.write(O,Q);return this.#K(O)}#M(O,Q){if(Q)this.emit(\"error\",Q);try{O(Q\?Q:null)}catch(U){this.emit(\"error\",U)}}#N(O,Q,U){if(!M(Q))return this.#J(),this.#B.write(O,Q,U);var V=this.#H();const X=V.write(O),Z=V.flush(!0);if(Z\?.then)return Z.then(()=>{this.#M(U),this.emit(\"drain\")},(Y)=>this.#M(U,Y)),!1;return queueMicrotask(()=>{this.#M(U)}),!!(X||Z)}write(O,Q,U){const V=this._write(O,Q,U);if(V)this.emit(\"drain\");return V}get hasColors(){return @Bun.tty[this.#$].hasColors}_write(O,Q,U){var V=this.#B;if(V)return V.write(O,Q,U);switch(arguments.length){case 0:{var X=new Error(\"Invalid arguments\");throw X.code=\"ERR_INVALID_ARG_TYPE\",X}case 1:return this.#K(O);case 2:if(typeof Q===\"function\")return this.#N(O,\"\",Q);else if(typeof Q===\"string\")return this.#L(O,Q);default:{if(typeof Q!==\"undefined\"&&typeof Q!==\"string\"||typeof U!==\"undefined\"&&typeof U!==\"function\"){var X=new Error(\"Invalid arguments\");throw X.code=\"ERR_INVALID_ARG_TYPE\",X}if(typeof U===\"undefined\")return this.#L(O,Q);return this.#N(O,Q,U)}}}destroy(){return this}end(){return this}};return new B(j)})\n";
+const char* const s_processObjectInternalsGetStdioWriteStreamCode = "(function (j,z){\"use strict\";var J={path:\"node:process\",require:z},K=(N)=>J.require(N);function G(N){var{Duplex:O,eos:Q,destroy:U}=K(\"node:stream\"),V=class X extends O{#$;#B;#j=!0;#z=!0;#G;#H;#J;#K;#L;#M;get isTTY(){return this.#M\?\?=K(\"node:tty\").isatty(N)}get fd(){return N}constructor(Z){super({readable:!0,writable:!0});this.#G=`/dev/fd/${Z}`}#N(Z){const Y=this.#H;if(this.#H=null,Y)Y(Z);else if(Z)this.destroy(Z);else if(!this.#j&&!this.#z)this.destroy()}_destroy(Z,Y){if(!Z&&this.#H!==null){var P=class A extends Error{code;name;constructor(T=\"The operation was aborted\",x=void 0){if(x!==void 0&&typeof x!==\"object\")throw new Error(`Invalid AbortError options:\\n\\n${JSON.stringify(x,null,2)}`);super(T,x);this.code=\"ABORT_ERR\",this.name=\"AbortError\"}};Z=new P}if(this.#J=null,this.#K=null,this.#H===null)Y(Z);else{if(this.#H=Y,this.#$)U(this.#$,Z);if(this.#B)U(this.#B,Z)}}_write(Z,Y,P){if(!this.#$){var{createWriteStream:A}=K(\"node:fs\"),T=this.#$=A(this.#G);T.on(\"finish\",()=>{if(this.#K){const x=this.#K;this.#K=null,x()}}),T.on(\"drain\",()=>{if(this.#J){const x=this.#J;this.#J=null,x()}}),Q(T,(x)=>{if(this.#z=!1,x)U(T,x);this.#N(x)})}if(T.write(Z,Y))P();else this.#J=P}_final(Z){this.#$&&this.#$.end(),this.#K=Z}#O(){var{createReadStream:Z}=K(\"node:fs\"),Y=this.#B=Z(this.#G);return Y.on(\"readable\",()=>{if(this.#L){const P=this.#L;this.#L=null,P()}else this.read()}),Y.on(\"end\",()=>{this.push(null)}),Q(Y,(P)=>{if(this.#j=!1,P)U(Y,P);this.#N(P)}),Y}_read(){var Z=this.#B;if(!Z)Z=this.#O();while(!0){const Y=Z.read();if(Y===null||!this.push(Y))return}}};return new V(N)}var{EventEmitter:H}=K(\"node:events\");function M(N){if(!N)return!0;var O=N.toLowerCase();return O===\"utf8\"||O===\"utf-8\"||O===\"buffer\"||O===\"binary\"}var L,B=class N extends H{#$;#B;#j;#z;bytesWritten=0;setDefaultEncoding(O){if(this.#B||!M(O))return this.#J(),this.#B.setDefaultEncoding(O)}#G(){switch(this.#$){case 1:{var O=@Bun.stdout.writer({highWaterMark:0});return O.unref(),O}case 2:{var O=@Bun.stderr.writer({highWaterMark:0});return O.unref(),O}default:throw new Error(\"Unsupported writer\")}}#H(){return this.#j\?\?=this.#G()}constructor(O){super();this.#$=O}get fd(){return this.#$}get isTTY(){return this.#z\?\?=K(\"node:tty\").isatty(this.#$)}cursorTo(O,Q,U){return(L\?\?=K(\"readline\")).cursorTo(this,O,Q,U)}moveCursor(O,Q,U){return(L\?\?=K(\"readline\")).moveCursor(this,O,Q,U)}clearLine(O,Q){return(L\?\?=K(\"readline\")).clearLine(this,O,Q)}clearScreenDown(O){return(L\?\?=K(\"readline\")).clearScreenDown(this,O)}ref(){this.#H().ref()}unref(){this.#H().unref()}on(O,Q){if(O===\"close\"||O===\"finish\")return this.#J(),this.#B.on(O,Q);if(O===\"drain\")return super.on(\"drain\",Q);if(O===\"error\")return super.on(\"error\",Q);return super.on(O,Q)}get _writableState(){return this.#J(),this.#B._writableState}get _readableState(){return this.#J(),this.#B._readableState}pipe(O){return this.#J(),this.#B.pipe(O)}unpipe(O){return this.#J(),this.#B.unpipe(O)}#J(){if(this.#B)return;this.#B=G(this.#$);const O=this.eventNames();for(let Q of O)this.#B.on(Q,(...U)=>{this.emit(Q,...U)})}#K(O){var Q=this.#H();const U=Q.write(O);this.bytesWritten+=U;const V=Q.flush(!1);return!!(U||V)}#L(O,Q){if(!M(Q))return this.#J(),this.#B.write(O,Q);return this.#K(O)}#M(O,Q){if(Q)this.emit(\"error\",Q);try{O(Q\?Q:null)}catch(U){this.emit(\"error\",U)}}#N(O,Q,U){if(!M(Q))return this.#J(),this.#B.write(O,Q,U);var V=this.#H();const X=V.write(O),Z=V.flush(!0);if(Z\?.then)return Z.then(()=>{this.#M(U),this.emit(\"drain\")},(Y)=>this.#M(U,Y)),!1;return queueMicrotask(()=>{this.#M(U)}),!!(X||Z)}write(O,Q,U){const V=this._write(O,Q,U);if(V)this.emit(\"drain\");return V}get hasColors(){return @Bun.tty[this.#$].hasColors}_write(O,Q,U){var V=this.#B;if(V)return V.write(O,Q,U);switch(arguments.length){case 0:{var X=new Error(\"Invalid arguments\");throw X.code=\"ERR_INVALID_ARG_TYPE\",X}case 1:return this.#K(O);case 2:if(typeof Q===\"function\")return this.#N(O,\"\",Q);else if(typeof Q===\"string\")return this.#L(O,Q);default:{if(typeof Q!==\"undefined\"&&typeof Q!==\"string\"||typeof U!==\"undefined\"&&typeof U!==\"function\"){var X=new Error(\"Invalid arguments\");throw X.code=\"ERR_INVALID_ARG_TYPE\",X}if(typeof U===\"undefined\")return this.#L(O,Q);return this.#N(O,Q,U)}}}destroy(){return this}end(){return this}};return new B(j)})\n";
// getStdinStream
const JSC::ConstructAbility s_processObjectInternalsGetStdinStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -656,7 +656,7 @@ const JSC::ConstructorKind s_processObjectInternalsGetStdinStreamCodeConstructor
const JSC::ImplementationVisibility s_processObjectInternalsGetStdinStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_processObjectInternalsGetStdinStreamCodeLength = 1799;
static const JSC::Intrinsic s_processObjectInternalsGetStdinStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_processObjectInternalsGetStdinStreamCode = "(function (z,G,H){\"use strict\";var K={path:\"node:process\",require:G},L=(T)=>K.require(T),{Duplex:M,eos:N,destroy:P}=L(\"node:stream\"),Q=class T extends M{#Y;#$;#j;#z=!0;#G=!1;#H=!0;#I;#J;#K;get isTTY(){return L(\"tty\").isatty(z)}get fd(){return z}constructor(){super({readable:!0,writable:!0})}#L(Y){const j=this.#J;if(this.#J=null,j)j(Y);else if(Y)this.destroy(Y);else if(!this.#z&&!this.#H)this.destroy()}_destroy(Y,j){if(!Y&&this.#J!==null){var I=class J extends Error{constructor(U=\"The operation was aborted\",V=void 0){if(V!==void 0&&typeof V!==\"object\")throw new Error(`Invalid AbortError options:\\n\\n${JSON.stringify(V,null,2)}`);super(U,V);this.code=\"ABORT_ERR\",this.name=\"AbortError\"}};Y=new I}if(this.#J===null)j(Y);else if(this.#J=j,this.#j)P(this.#j,Y)}setRawMode(Y){}on(Y,j){if(Y===\"readable\")this.ref(),this.#G=!0;return super.on(Y,j)}pause(){return this.unref(),super.pause()}resume(){return this.ref(),super.resume()}ref(){this.#Y\?\?=H.stdin.stream().getReader(),this.#$\?\?=setInterval(()=>{},1<<30)}unref(){if(this.#$)clearInterval(this.#$),this.#$=null}async#M(){try{var Y,j;const I=this.#Y.readMany();if(!I\?.then)({done:Y,value:j}=I);else({done:Y,value:j}=await I);if(!Y){this.push(j[0]);const J=j.length;for(let U=1;U<J;U++)this.push(j[U])}else this.push(null),this.pause(),this.#z=!1,this.#L()}catch(I){this.#z=!1,this.#L(I)}}_read(Y){if(this.#G)this.unref(),this.#G=!1;this.#M()}#N(){var{createWriteStream:Y}=L(\"node:fs\"),j=this.#j=Y(\"/dev/fd/0\");return j.on(\"finish\",()=>{if(this.#I){const I=this.#I;this.#I=null,I()}}),j.on(\"drain\",()=>{if(this.#K){const I=this.#K;this.#K=null,I()}}),N(j,(I)=>{if(this.#H=!1,I)P(j,I);this.#L(I)}),j}_write(Y,j,I){var J=this.#j;if(!J)J=this.#N();if(J.write(Y,j))I();else this.#K=I}_final(Y){this.#j.end(),this.#I=(...j)=>Y(...j)}};return new Q})\n";
+const char* const s_processObjectInternalsGetStdinStreamCode = "(function (z,G,I){\"use strict\";var K={path:\"node:process\",require:G},L=(T)=>K.require(T),{Duplex:M,eos:N,destroy:P}=L(\"node:stream\"),Q=class T extends M{#Y;#$;#j;#z=!0;#G=!1;#H=!0;#I;#J;#K;get isTTY(){return L(\"tty\").isatty(z)}get fd(){return z}constructor(){super({readable:!0,writable:!0})}#L(Y){const j=this.#J;if(this.#J=null,j)j(Y);else if(Y)this.destroy(Y);else if(!this.#z&&!this.#H)this.destroy()}_destroy(Y,j){if(!Y&&this.#J!==null){var H=class J extends Error{constructor(U=\"The operation was aborted\",V=void 0){if(V!==void 0&&typeof V!==\"object\")throw new Error(`Invalid AbortError options:\\n\\n${JSON.stringify(V,null,2)}`);super(U,V);this.code=\"ABORT_ERR\",this.name=\"AbortError\"}};Y=new H}if(this.#J===null)j(Y);else if(this.#J=j,this.#j)P(this.#j,Y)}setRawMode(Y){}on(Y,j){if(Y===\"readable\")this.ref(),this.#G=!0;return super.on(Y,j)}pause(){return this.unref(),super.pause()}resume(){return this.ref(),super.resume()}ref(){this.#Y\?\?=I.stdin.stream().getReader(),this.#$\?\?=setInterval(()=>{},1<<30)}unref(){if(this.#$)clearInterval(this.#$),this.#$=null}async#M(){try{var Y,j;const H=this.#Y.readMany();if(!H\?.then)({done:Y,value:j}=H);else({done:Y,value:j}=await H);if(!Y){this.push(j[0]);const J=j.length;for(let U=1;U<J;U++)this.push(j[U])}else this.push(null),this.pause(),this.#z=!1,this.#L()}catch(H){this.#z=!1,this.#L(H)}}_read(Y){if(this.#G)this.unref(),this.#G=!1;this.#M()}#N(){var{createWriteStream:Y}=L(\"node:fs\"),j=this.#j=Y(\"/dev/fd/0\");return j.on(\"finish\",()=>{if(this.#I){const H=this.#I;this.#I=null,H()}}),j.on(\"drain\",()=>{if(this.#K){const H=this.#K;this.#K=null,H()}}),N(j,(H)=>{if(this.#H=!1,H)P(j,H);this.#L(H)}),j}_write(Y,j,H){var J=this.#j;if(!J)J=this.#N();if(J.write(Y,j))H();else this.#K=H}_final(Y){this.#j.end(),this.#I=(...j)=>Y(...j)}};return new Q})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \
@@ -674,7 +674,7 @@ const JSC::ConstructorKind s_transformStreamInitializeTransformStreamCodeConstru
const JSC::ImplementationVisibility s_transformStreamInitializeTransformStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_transformStreamInitializeTransformStreamCodeLength = 1334;
static const JSC::Intrinsic s_transformStreamInitializeTransformStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_transformStreamInitializeTransformStreamCode = "(function (){\"use strict\";let j=arguments[0];if(@isObject(j)&&@getByIdDirectPrivate(j,\"TransformStream\"))return this;let E=arguments[1],_=arguments[2];if(j===@undefined)j=null;if(_===@undefined)_={};if(E===@undefined)E={};let F={};if(j!==null){if(\"start\"in j){if(F[\"start\"]=j[\"start\"],typeof F[\"start\"]!==\"function\")@throwTypeError(\"transformer.start should be a function\")}if(\"transform\"in j){if(F[\"transform\"]=j[\"transform\"],typeof F[\"transform\"]!==\"function\")@throwTypeError(\"transformer.transform should be a function\")}if(\"flush\"in j){if(F[\"flush\"]=j[\"flush\"],typeof F[\"flush\"]!==\"function\")@throwTypeError(\"transformer.flush should be a function\")}if(\"readableType\"in j)@throwRangeError(\"TransformStream transformer has a readableType\");if(\"writableType\"in j)@throwRangeError(\"TransformStream transformer has a writableType\")}const q=@extractHighWaterMark(_,0),G=@extractSizeAlgorithm(_),v=@extractHighWaterMark(E,1),I=@extractSizeAlgorithm(E),x=@newPromiseCapability(@Promise);if(@initializeTransformStream(this,x.@promise,v,I,q,G),@setUpTransformStreamDefaultControllerFromTransformer(this,j,F),(\"start\"in F)){const J=@getByIdDirectPrivate(this,\"controller\");(()=>@promiseInvokeOrNoopMethodNoCatch(j,F[\"start\"],[J]))().@then(()=>{x.@resolve.@call()},(u)=>{x.@reject.@call(@undefined,u)})}else x.@resolve.@call();return this})\n";
+const char* const s_transformStreamInitializeTransformStreamCode = "(function (){\"use strict\";let j=arguments[0];if(@isObject(j)&&@getByIdDirectPrivate(j,\"TransformStream\"))return this;let q=arguments[1],v=arguments[2];if(j===@undefined)j=null;if(v===@undefined)v={};if(q===@undefined)q={};let x={};if(j!==null){if(\"start\"in j){if(x[\"start\"]=j[\"start\"],typeof x[\"start\"]!==\"function\")@throwTypeError(\"transformer.start should be a function\")}if(\"transform\"in j){if(x[\"transform\"]=j[\"transform\"],typeof x[\"transform\"]!==\"function\")@throwTypeError(\"transformer.transform should be a function\")}if(\"flush\"in j){if(x[\"flush\"]=j[\"flush\"],typeof x[\"flush\"]!==\"function\")@throwTypeError(\"transformer.flush should be a function\")}if(\"readableType\"in j)@throwRangeError(\"TransformStream transformer has a readableType\");if(\"writableType\"in j)@throwRangeError(\"TransformStream transformer has a writableType\")}const B=@extractHighWaterMark(v,0),E=@extractSizeAlgorithm(v),F=@extractHighWaterMark(q,1),G=@extractSizeAlgorithm(q),I=@newPromiseCapability(@Promise);if(@initializeTransformStream(this,I.@promise,F,G,B,E),@setUpTransformStreamDefaultControllerFromTransformer(this,j,x),(\"start\"in x)){const J=@getByIdDirectPrivate(this,\"controller\");(()=>@promiseInvokeOrNoopMethodNoCatch(j,x[\"start\"],[J]))().@then(()=>{I.@resolve.@call()},(u)=>{I.@reject.@call(@undefined,u)})}else I.@resolve.@call();return this})\n";
// readable
const JSC::ConstructAbility s_transformStreamReadableCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -846,7 +846,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeReadUIntLECodeConstructorKind = JS
const JSC::ImplementationVisibility s_jsBufferPrototypeReadUIntLECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeReadUIntLECodeLength = 445;
static const JSC::Intrinsic s_jsBufferPrototypeReadUIntLECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeReadUIntLECode = "(function (a,r){\"use strict\";const d=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(r){case 1:return d.getUint8(a);case 2:return d.getUint16(a,!0);case 3:return d.getUint16(a,!0)+d.getUint8(a+2)*65536;case 4:return d.getUint32(a,!0);case 5:return d.getUint8(a+4)*4294967296+d.getUint32(a,!0);case 6:return d.getUint16(a+4,!0)*4294967296+d.getUint32(a,!0)}@throwRangeError(\"byteLength must be >= 1 and <= 6\")})\n";
+const char* const s_jsBufferPrototypeReadUIntLECode = "(function (a,d){\"use strict\";const r=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(d){case 1:return r.getUint8(a);case 2:return r.getUint16(a,!0);case 3:return r.getUint16(a,!0)+r.getUint8(a+2)*65536;case 4:return r.getUint32(a,!0);case 5:return r.getUint8(a+4)*4294967296+r.getUint32(a,!0);case 6:return r.getUint16(a+4,!0)*4294967296+r.getUint32(a,!0)}@throwRangeError(\"byteLength must be >= 1 and <= 6\")})\n";
// readUIntBE
const JSC::ConstructAbility s_jsBufferPrototypeReadUIntBECodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -854,7 +854,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeReadUIntBECodeConstructorKind = JS
const JSC::ImplementationVisibility s_jsBufferPrototypeReadUIntBECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeReadUIntBECodeLength = 504;
static const JSC::Intrinsic s_jsBufferPrototypeReadUIntBECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeReadUIntBECode = "(function (d,r){\"use strict\";const c=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(r){case 1:return c.getUint8(d);case 2:return c.getUint16(d,!1);case 3:return c.getUint16(d+1,!1)+c.getUint8(d)*65536;case 4:return c.getUint32(d,!1);case 5:{const p=c.getUint8(d);return(p|(p&128)*33554430)*4294967296+c.getUint32(d+1,!1)}case 6:{const p=c.getUint16(d,!1);return(p|(p&32768)*131070)*4294967296+c.getUint32(d+2,!1)}}@throwRangeError(\"byteLength must be >= 1 and <= 6\")})\n";
+const char* const s_jsBufferPrototypeReadUIntBECode = "(function (d,r){\"use strict\";const p=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(r){case 1:return p.getUint8(d);case 2:return p.getUint16(d,!1);case 3:return p.getUint16(d+1,!1)+p.getUint8(d)*65536;case 4:return p.getUint32(d,!1);case 5:{const c=p.getUint8(d);return(c|(c&128)*33554430)*4294967296+p.getUint32(d+1,!1)}case 6:{const c=p.getUint16(d,!1);return(c|(c&32768)*131070)*4294967296+p.getUint32(d+2,!1)}}@throwRangeError(\"byteLength must be >= 1 and <= 6\")})\n";
// readFloatLE
const JSC::ConstructAbility s_jsBufferPrototypeReadFloatLECodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1006,7 +1006,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeWriteIntLECodeConstructorKind = JS
const JSC::ImplementationVisibility s_jsBufferPrototypeWriteIntLECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeWriteIntLECodeLength = 573;
static const JSC::Intrinsic s_jsBufferPrototypeWriteIntLECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeWriteIntLECode = "(function (d,r,j){\"use strict\";const c=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(j){case 1:{c.setInt8(r,d);break}case 2:{c.setInt16(r,d,!0);break}case 3:{c.setUint16(r,d&65535,!0),c.setInt8(r+2,Math.floor(d*0.0000152587890625));break}case 4:{c.setInt32(r,d,!0);break}case 5:{c.setUint32(r,d|0,!0),c.setInt8(r+4,Math.floor(d*0.00000000023283064365386964));break}case 6:{c.setUint32(r,d|0,!0),c.setInt16(r+4,Math.floor(d*0.00000000023283064365386964),!0);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return r+j})\n";
+const char* const s_jsBufferPrototypeWriteIntLECode = "(function (d,r,c){\"use strict\";const j=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(c){case 1:{j.setInt8(r,d);break}case 2:{j.setInt16(r,d,!0);break}case 3:{j.setUint16(r,d&65535,!0),j.setInt8(r+2,Math.floor(d*0.0000152587890625));break}case 4:{j.setInt32(r,d,!0);break}case 5:{j.setUint32(r,d|0,!0),j.setInt8(r+4,Math.floor(d*0.00000000023283064365386964));break}case 6:{j.setUint32(r,d|0,!0),j.setInt16(r+4,Math.floor(d*0.00000000023283064365386964),!0);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return r+c})\n";
// writeIntBE
const JSC::ConstructAbility s_jsBufferPrototypeWriteIntBECodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1022,7 +1022,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeWriteUIntLECodeConstructorKind = J
const JSC::ImplementationVisibility s_jsBufferPrototypeWriteUIntLECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeWriteUIntLECodeLength = 579;
static const JSC::Intrinsic s_jsBufferPrototypeWriteUIntLECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeWriteUIntLECode = "(function (d,r,E){\"use strict\";const c=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(E){case 1:{c.setUint8(r,d);break}case 2:{c.setUint16(r,d,!0);break}case 3:{c.setUint16(r,d&65535,!0),c.setUint8(r+2,Math.floor(d*0.0000152587890625));break}case 4:{c.setUint32(r,d,!0);break}case 5:{c.setUint32(r,d|0,!0),c.setUint8(r+4,Math.floor(d*0.00000000023283064365386964));break}case 6:{c.setUint32(r,d|0,!0),c.setUint16(r+4,Math.floor(d*0.00000000023283064365386964),!0);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return r+E})\n";
+const char* const s_jsBufferPrototypeWriteUIntLECode = "(function (d,r,c){\"use strict\";const E=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(c){case 1:{E.setUint8(r,d);break}case 2:{E.setUint16(r,d,!0);break}case 3:{E.setUint16(r,d&65535,!0),E.setUint8(r+2,Math.floor(d*0.0000152587890625));break}case 4:{E.setUint32(r,d,!0);break}case 5:{E.setUint32(r,d|0,!0),E.setUint8(r+4,Math.floor(d*0.00000000023283064365386964));break}case 6:{E.setUint32(r,d|0,!0),E.setUint16(r+4,Math.floor(d*0.00000000023283064365386964),!0);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return r+c})\n";
// writeUIntBE
const JSC::ConstructAbility s_jsBufferPrototypeWriteUIntBECodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1030,7 +1030,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeWriteUIntBECodeConstructorKind = J
const JSC::ImplementationVisibility s_jsBufferPrototypeWriteUIntBECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeWriteUIntBECodeLength = 579;
static const JSC::Intrinsic s_jsBufferPrototypeWriteUIntBECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeWriteUIntBECode = "(function (p,_,r){\"use strict\";const d=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(r){case 1:{d.setUint8(_,p);break}case 2:{d.setUint16(_,p,!1);break}case 3:{d.setUint16(_+1,p&65535,!1),d.setUint8(_,Math.floor(p*0.0000152587890625));break}case 4:{d.setUint32(_,p,!1);break}case 5:{d.setUint32(_+1,p|0,!1),d.setUint8(_,Math.floor(p*0.00000000023283064365386964));break}case 6:{d.setUint32(_+2,p|0,!1),d.setUint16(_,Math.floor(p*0.00000000023283064365386964),!1);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return _+r})\n";
+const char* const s_jsBufferPrototypeWriteUIntBECode = "(function (d,r,p){\"use strict\";const _=this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength);switch(p){case 1:{_.setUint8(r,d);break}case 2:{_.setUint16(r,d,!1);break}case 3:{_.setUint16(r+1,d&65535,!1),_.setUint8(r,Math.floor(d*0.0000152587890625));break}case 4:{_.setUint32(r,d,!1);break}case 5:{_.setUint32(r+1,d|0,!1),_.setUint8(r,Math.floor(d*0.00000000023283064365386964));break}case 6:{_.setUint32(r+2,d|0,!1),_.setUint16(r,Math.floor(d*0.00000000023283064365386964),!1);break}default:@throwRangeError(\"byteLength must be >= 1 and <= 6\")}return r+p})\n";
// writeFloatLE
const JSC::ConstructAbility s_jsBufferPrototypeWriteFloatLECodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1094,7 +1094,7 @@ const JSC::ConstructorKind s_jsBufferPrototypeWriteBigUInt64BECodeConstructorKin
const JSC::ImplementationVisibility s_jsBufferPrototypeWriteBigUInt64BECodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_jsBufferPrototypeWriteBigUInt64BECodeLength = 139;
static const JSC::Intrinsic s_jsBufferPrototypeWriteBigUInt64BECodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_jsBufferPrototypeWriteBigUInt64BECode = "(function (c,d){\"use strict\";return(this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength)).setBigUint64(d,c,!1),d+8})\n";
+const char* const s_jsBufferPrototypeWriteBigUInt64BECode = "(function (d,c){\"use strict\";return(this.@dataView||=new DataView(this.buffer,this.byteOffset,this.byteLength)).setBigUint64(c,d,!1),c+8})\n";
// utf8Write
const JSC::ConstructAbility s_jsBufferPrototypeUtf8WriteCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1338,7 +1338,7 @@ const JSC::ConstructorKind s_consoleObjectAsyncIteratorCodeConstructorKind = JSC
const JSC::ImplementationVisibility s_consoleObjectAsyncIteratorCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_consoleObjectAsyncIteratorCodeLength = 577;
static const JSC::Intrinsic s_consoleObjectAsyncIteratorCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_consoleObjectAsyncIteratorCode = "(function (){\"use strict\";const w=async function*_(){var D=@Bun.stdin.stream().getReader(),F=new globalThis.TextDecoder(\"utf-8\",{fatal:!1}),H,J=@Bun.indexOfLine;try{while(!0){var K,m,L;const B=D.readMany();if(@isPromise(B))({done:K,value:m}=await B);else({done:K,value:m}=B);if(K){if(L)yield F.decode(L);return}var M;for(let z of m){if(M=z,L)M=@Buffer.concat([L,z]),L=null;var q=0,A=J(M,q);while(A!==-1)yield F.decode(M.subarray(q,A)),q=A+1,A=J(M,q);L=M.subarray(q)}}}catch(B){H=B}finally{if(D.releaseLock(),H)throw H}},G=globalThis.Symbol.asyncIterator;return this[G]=w,w()})\n";
+const char* const s_consoleObjectAsyncIteratorCode = "(function (){\"use strict\";const w=async function*_(){var A=@Bun.stdin.stream().getReader(),F=new globalThis.TextDecoder(\"utf-8\",{fatal:!1}),H,J=@Bun.indexOfLine;try{while(!0){var K,m,L;const D=A.readMany();if(@isPromise(D))({done:K,value:m}=await D);else({done:K,value:m}=D);if(K){if(L)yield F.decode(L);return}var M;for(let z of m){if(M=z,L)M=@Buffer.concat([L,z]),L=null;var q=0,B=J(M,q);while(B!==-1)yield F.decode(M.subarray(q,B)),q=B+1,B=J(M,q);L=M.subarray(q)}}}catch(D){H=D}finally{if(A.releaseLock(),H)throw H}},G=globalThis.Symbol.asyncIterator;return this[G]=w,w()})\n";
// write
const JSC::ConstructAbility s_consoleObjectWriteCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1346,7 +1346,7 @@ const JSC::ConstructorKind s_consoleObjectWriteCodeConstructorKind = JSC::Constr
const JSC::ImplementationVisibility s_consoleObjectWriteCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_consoleObjectWriteCodeLength = 310;
static const JSC::Intrinsic s_consoleObjectWriteCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_consoleObjectWriteCode = "(function (a){\"use strict\";var d=@getByIdDirectPrivate(this,\"writer\");if(!d){var _=@toLength(a\?.length\?\?0);d=@Bun.stdout.writer({highWaterMark:_>65536\?_:65536}),@putByIdDirectPrivate(this,\"writer\",d)}var b=d.write(a);const c=@argumentCount();for(var f=1;f<c;f++)b+=d.write(@argument(f));return d.flush(!0),b})\n";
+const char* const s_consoleObjectWriteCode = "(function (d){\"use strict\";var _=@getByIdDirectPrivate(this,\"writer\");if(!_){var b=@toLength(d\?.length\?\?0);_=@Bun.stdout.writer({highWaterMark:b>65536\?b:65536}),@putByIdDirectPrivate(this,\"writer\",_)}var c=_.write(d);const f=@argumentCount();for(var a=1;a<f;a++)c+=_.write(@argument(a));return _.flush(!0),c})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \
@@ -1388,7 +1388,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamPipeToCodeCons
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamPipeToCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamPipeToCodeLength = 427;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamPipeToCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamPipeToCode = "(function (_,c){\"use strict\";@assert(@isReadableStream(_));const g=new @ReadableStreamDefaultReader(_);@getByIdDirectPrivate(g,\"closedPromiseCapability\").@promise.@then(()=>{},(y)=>{c.error(y)});function h(){@readableStreamDefaultReaderRead(g).@then(function(y){if(y.done){c.close();return}try{c.enqueue(y.value)}catch(S){c.error(\"ReadableStream chunk enqueueing in the sink failed\");return}h()},function(y){c.error(y)})}h()})\n";
+const char* const s_readableStreamInternalsReadableStreamPipeToCode = "(function (c,g){\"use strict\";@assert(@isReadableStream(c));const h=new @ReadableStreamDefaultReader(c);@getByIdDirectPrivate(h,\"closedPromiseCapability\").@promise.@then(()=>{},(S)=>{g.error(S)});function y(){@readableStreamDefaultReaderRead(h).@then(function(S){if(S.done){g.close();return}try{g.enqueue(S.value)}catch(_){g.error(\"ReadableStream chunk enqueueing in the sink failed\");return}y()},function(S){g.error(S)})}y()})\n";
// acquireReadableStreamDefaultReader
const JSC::ConstructAbility s_readableStreamInternalsAcquireReadableStreamDefaultReaderCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1404,7 +1404,7 @@ const JSC::ConstructorKind s_readableStreamInternalsSetupReadableStreamDefaultCo
const JSC::ImplementationVisibility s_readableStreamInternalsSetupReadableStreamDefaultControllerCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsSetupReadableStreamDefaultControllerCodeLength = 523;
static const JSC::Intrinsic s_readableStreamInternalsSetupReadableStreamDefaultControllerCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsSetupReadableStreamDefaultControllerCode = "(function (_,q,f,j,w,v,x){\"use strict\";const B=new @ReadableStreamDefaultController(_,q,f,j,@isReadableStream),C=()=>@promiseInvokeOrNoopMethod(q,v,[B]),b=(D)=>@promiseInvokeOrNoopMethod(q,x,[D]);@putByIdDirectPrivate(B,\"pullAlgorithm\",C),@putByIdDirectPrivate(B,\"cancelAlgorithm\",b),@putByIdDirectPrivate(B,\"pull\",@readableStreamDefaultControllerPull),@putByIdDirectPrivate(B,\"cancel\",@readableStreamDefaultControllerCancel),@putByIdDirectPrivate(_,\"readableStreamController\",B),@readableStreamDefaultControllerStart(B)})\n";
+const char* const s_readableStreamInternalsSetupReadableStreamDefaultControllerCode = "(function (_,w,f,b,q,v,x){\"use strict\";const B=new @ReadableStreamDefaultController(_,w,f,b,@isReadableStream),C=()=>@promiseInvokeOrNoopMethod(w,v,[B]),j=(D)=>@promiseInvokeOrNoopMethod(w,x,[D]);@putByIdDirectPrivate(B,\"pullAlgorithm\",C),@putByIdDirectPrivate(B,\"cancelAlgorithm\",j),@putByIdDirectPrivate(B,\"pull\",@readableStreamDefaultControllerPull),@putByIdDirectPrivate(B,\"cancel\",@readableStreamDefaultControllerCancel),@putByIdDirectPrivate(_,\"readableStreamController\",B),@readableStreamDefaultControllerStart(B)})\n";
// createReadableStreamController
const JSC::ConstructAbility s_readableStreamInternalsCreateReadableStreamControllerCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1428,7 +1428,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamPipeToWritable
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamPipeToWritableStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamPipeToWritableStreamCodeLength = 1631;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamPipeToWritableStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamPipeToWritableStreamCode = "(function (_,F,f,D,z,B){\"use strict\";if(@assert(@isReadableStream(_)),@assert(@isWritableStream(F)),@assert(!@isReadableStreamLocked(_)),@assert(!@isWritableStreamLocked(F)),@assert(B===@undefined||@isAbortSignal(B)),@getByIdDirectPrivate(_,\"underlyingByteSource\")!==@undefined)return @Promise.@reject(\"Piping to a readable bytestream is not supported\");let G={source:_,destination:F,preventAbort:D,preventCancel:z,preventClose:f,signal:B};if(G.reader=@acquireReadableStreamDefaultReader(_),G.writer=@acquireWritableStreamDefaultWriter(F),@putByIdDirectPrivate(_,\"disturbed\",!0),G.finalized=!1,G.shuttingDown=!1,G.promiseCapability=@newPromiseCapability(@Promise),G.pendingReadPromiseCapability=@newPromiseCapability(@Promise),G.pendingReadPromiseCapability.@resolve.@call(),G.pendingWritePromise=@Promise.@resolve(),B!==@undefined){const H=(I)=>{if(G.finalized)return;@pipeToShutdownWithAction(G,()=>{const J=!G.preventAbort&&@getByIdDirectPrivate(G.destination,\"state\")===\"writable\"\?@writableStreamAbort(G.destination,I):@Promise.@resolve(),T=!G.preventCancel&&@getByIdDirectPrivate(G.source,\"state\")===@streamReadable\?@readableStreamCancel(G.source,I):@Promise.@resolve();let w=@newPromiseCapability(@Promise),x=!0,k=()=>{if(x){x=!1;return}w.@resolve.@call()},q=(L)=>{w.@reject.@call(@undefined,L)};return J.@then(k,q),T.@then(k,q),w.@promise},I)};if(@whenSignalAborted(B,H))return G.promiseCapability.@promise}return @pipeToErrorsMustBePropagatedForward(G),@pipeToErrorsMustBePropagatedBackward(G),@pipeToClosingMustBePropagatedForward(G),@pipeToClosingMustBePropagatedBackward(G),@pipeToLoop(G),G.promiseCapability.@promise})\n";
+const char* const s_readableStreamInternalsReadableStreamPipeToWritableStreamCode = "(function (_,x,G,q,H,z){\"use strict\";if(@assert(@isReadableStream(_)),@assert(@isWritableStream(x)),@assert(!@isReadableStreamLocked(_)),@assert(!@isWritableStreamLocked(x)),@assert(z===@undefined||@isAbortSignal(z)),@getByIdDirectPrivate(_,\"underlyingByteSource\")!==@undefined)return @Promise.@reject(\"Piping to a readable bytestream is not supported\");let I={source:_,destination:x,preventAbort:q,preventCancel:H,preventClose:G,signal:z};if(I.reader=@acquireReadableStreamDefaultReader(_),I.writer=@acquireWritableStreamDefaultWriter(x),@putByIdDirectPrivate(_,\"disturbed\",!0),I.finalized=!1,I.shuttingDown=!1,I.promiseCapability=@newPromiseCapability(@Promise),I.pendingReadPromiseCapability=@newPromiseCapability(@Promise),I.pendingReadPromiseCapability.@resolve.@call(),I.pendingWritePromise=@Promise.@resolve(),z!==@undefined){const w=(f)=>{if(I.finalized)return;@pipeToShutdownWithAction(I,()=>{const J=!I.preventAbort&&@getByIdDirectPrivate(I.destination,\"state\")===\"writable\"\?@writableStreamAbort(I.destination,f):@Promise.@resolve(),E=!I.preventCancel&&@getByIdDirectPrivate(I.source,\"state\")===@streamReadable\?@readableStreamCancel(I.source,f):@Promise.@resolve();let K=@newPromiseCapability(@Promise),T=!0,L=()=>{if(T){T=!1;return}K.@resolve.@call()},k=(F)=>{K.@reject.@call(@undefined,F)};return J.@then(L,k),E.@then(L,k),K.@promise},f)};if(@whenSignalAborted(z,w))return I.promiseCapability.@promise}return @pipeToErrorsMustBePropagatedForward(I),@pipeToErrorsMustBePropagatedBackward(I),@pipeToClosingMustBePropagatedForward(I),@pipeToClosingMustBePropagatedBackward(I),@pipeToLoop(I),I.promiseCapability.@promise})\n";
// pipeToLoop
const JSC::ConstructAbility s_readableStreamInternalsPipeToLoopCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1460,7 +1460,7 @@ const JSC::ConstructorKind s_readableStreamInternalsPipeToErrorsMustBePropagated
const JSC::ImplementationVisibility s_readableStreamInternalsPipeToErrorsMustBePropagatedBackwardCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsPipeToErrorsMustBePropagatedBackwardCodeLength = 369;
static const JSC::Intrinsic s_readableStreamInternalsPipeToErrorsMustBePropagatedBackwardCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsPipeToErrorsMustBePropagatedBackwardCode = "(function (m){\"use strict\";const h=()=>{const y=@getByIdDirectPrivate(m.destination,\"storedError\");if(!m.preventCancel){@pipeToShutdownWithAction(m,()=>@readableStreamCancel(m.source,y),y);return}@pipeToShutdown(m,y)};if(@getByIdDirectPrivate(m.destination,\"state\")===\"errored\"){h();return}@getByIdDirectPrivate(m.writer,\"closedPromise\").@promise.@then(@undefined,h)})\n";
+const char* const s_readableStreamInternalsPipeToErrorsMustBePropagatedBackwardCode = "(function (m){\"use strict\";const y=()=>{const h=@getByIdDirectPrivate(m.destination,\"storedError\");if(!m.preventCancel){@pipeToShutdownWithAction(m,()=>@readableStreamCancel(m.source,h),h);return}@pipeToShutdown(m,h)};if(@getByIdDirectPrivate(m.destination,\"state\")===\"errored\"){y();return}@getByIdDirectPrivate(m.writer,\"closedPromise\").@promise.@then(@undefined,y)})\n";
// pipeToClosingMustBePropagatedForward
const JSC::ConstructAbility s_readableStreamInternalsPipeToClosingMustBePropagatedForwardCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1484,7 +1484,7 @@ const JSC::ConstructorKind s_readableStreamInternalsPipeToShutdownWithActionCode
const JSC::ImplementationVisibility s_readableStreamInternalsPipeToShutdownWithActionCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsPipeToShutdownWithActionCodeLength = 458;
static const JSC::Intrinsic s_readableStreamInternalsPipeToShutdownWithActionCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsPipeToShutdownWithActionCode = "(function (_,b){\"use strict\";if(_.shuttingDown)return;_.shuttingDown=!0;const g=arguments.length>2,d=arguments[2],h=()=>{b().@then(()=>{if(g)@pipeToFinalize(_,d);else @pipeToFinalize(_)},(m)=>{@pipeToFinalize(_,m)})};if(@getByIdDirectPrivate(_.destination,\"state\")===\"writable\"&&!@writableStreamCloseQueuedOrInFlight(_.destination)){_.pendingReadPromiseCapability.@promise.@then(()=>{_.pendingWritePromise.@then(h,h)},(j)=>@pipeToFinalize(_,j));return}h()})\n";
+const char* const s_readableStreamInternalsPipeToShutdownWithActionCode = "(function (_,m){\"use strict\";if(_.shuttingDown)return;_.shuttingDown=!0;const b=arguments.length>2,d=arguments[2],g=()=>{m().@then(()=>{if(b)@pipeToFinalize(_,d);else @pipeToFinalize(_)},(j)=>{@pipeToFinalize(_,j)})};if(@getByIdDirectPrivate(_.destination,\"state\")===\"writable\"&&!@writableStreamCloseQueuedOrInFlight(_.destination)){_.pendingReadPromiseCapability.@promise.@then(()=>{_.pendingWritePromise.@then(g,g)},(h)=>@pipeToFinalize(_,h));return}g()})\n";
// pipeToShutdown
const JSC::ConstructAbility s_readableStreamInternalsPipeToShutdownCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1508,7 +1508,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamTeeCodeConstru
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamTeeCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamTeeCodeLength = 1104;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamTeeCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamTeeCode = "(function (f,g){\"use strict\";@assert(@isReadableStream(f)),@assert(typeof g===\"boolean\");var j=@getByIdDirectPrivate(f,\"start\");if(j)@putByIdDirectPrivate(f,\"start\",@undefined),j();const k=new @ReadableStreamDefaultReader(f),i={closedOrErrored:!1,canceled1:!1,canceled2:!1,reason1:@undefined,reason2:@undefined};i.cancelPromiseCapability=@newPromiseCapability(@Promise);const w=@readableStreamTeePullFunction(i,k,g),_={};@putByIdDirectPrivate(_,\"pull\",w),@putByIdDirectPrivate(_,\"cancel\",@readableStreamTeeBranch1CancelFunction(i,f));const x={};@putByIdDirectPrivate(x,\"pull\",w),@putByIdDirectPrivate(x,\"cancel\",@readableStreamTeeBranch2CancelFunction(i,f));const y=new @ReadableStream(_),q=new @ReadableStream(x);return @getByIdDirectPrivate(k,\"closedPromiseCapability\").@promise.@then(@undefined,function(v){if(i.closedOrErrored)return;if(@readableStreamDefaultControllerError(y.@readableStreamController,v),@readableStreamDefaultControllerError(q.@readableStreamController,v),i.closedOrErrored=!0,!i.canceled1||!i.canceled2)i.cancelPromiseCapability.@resolve.@call()}),i.branch1=y,i.branch2=q,[y,q]})\n";
+const char* const s_readableStreamInternalsReadableStreamTeeCode = "(function (f,k){\"use strict\";@assert(@isReadableStream(f)),@assert(typeof k===\"boolean\");var i=@getByIdDirectPrivate(f,\"start\");if(i)@putByIdDirectPrivate(f,\"start\",@undefined),i();const q=new @ReadableStreamDefaultReader(f),_={closedOrErrored:!1,canceled1:!1,canceled2:!1,reason1:@undefined,reason2:@undefined};_.cancelPromiseCapability=@newPromiseCapability(@Promise);const v=@readableStreamTeePullFunction(_,q,k),g={};@putByIdDirectPrivate(g,\"pull\",v),@putByIdDirectPrivate(g,\"cancel\",@readableStreamTeeBranch1CancelFunction(_,f));const w={};@putByIdDirectPrivate(w,\"pull\",v),@putByIdDirectPrivate(w,\"cancel\",@readableStreamTeeBranch2CancelFunction(_,f));const x=new @ReadableStream(g),j=new @ReadableStream(w);return @getByIdDirectPrivate(q,\"closedPromiseCapability\").@promise.@then(@undefined,function(y){if(_.closedOrErrored)return;if(@readableStreamDefaultControllerError(x.@readableStreamController,y),@readableStreamDefaultControllerError(j.@readableStreamController,y),_.closedOrErrored=!0,!_.canceled1||!_.canceled2)_.cancelPromiseCapability.@resolve.@call()}),_.branch1=x,_.branch2=j,[x,j]})\n";
// readableStreamTeePullFunction
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamTeePullFunctionCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1524,7 +1524,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamTeeBranch1Canc
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamTeeBranch1CancelFunctionCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamTeeBranch1CancelFunctionCodeLength = 258;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamTeeBranch1CancelFunctionCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamTeeBranch1CancelFunctionCode = "(function (c,d){\"use strict\";return function(i){if(c.canceled1=!0,c.reason1=i,c.canceled2)@readableStreamCancel(d,[c.reason1,c.reason2]).@then(c.cancelPromiseCapability.@resolve,c.cancelPromiseCapability.@reject);return c.cancelPromiseCapability.@promise}})\n";
+const char* const s_readableStreamInternalsReadableStreamTeeBranch1CancelFunctionCode = "(function (c,i){\"use strict\";return function(d){if(c.canceled1=!0,c.reason1=d,c.canceled2)@readableStreamCancel(i,[c.reason1,c.reason2]).@then(c.cancelPromiseCapability.@resolve,c.cancelPromiseCapability.@reject);return c.cancelPromiseCapability.@promise}})\n";
// readableStreamTeeBranch2CancelFunction
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamTeeBranch2CancelFunctionCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1564,7 +1564,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadDirectStreamCodeConstruc
const JSC::ImplementationVisibility s_readableStreamInternalsReadDirectStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadDirectStreamCodeLength = 903;
static const JSC::Intrinsic s_readableStreamInternalsReadDirectStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadDirectStreamCode = "(function (B,v,_){\"use strict\";@putByIdDirectPrivate(B,\"underlyingSource\",@undefined),@putByIdDirectPrivate(B,\"start\",@undefined);function w(j,z){var A=_\?.cancel;if(A){try{var q=A.@apply(_,z);if(@isPromise(q))@markPromiseAsHandled(q)}catch(C){}_=@undefined}if(j)if(@putByIdDirectPrivate(j,\"readableStreamController\",@undefined),@putByIdDirectPrivate(j,\"reader\",@undefined),z)@putByIdDirectPrivate(j,\"state\",@streamErrored),@putByIdDirectPrivate(j,\"storedError\",z);else @putByIdDirectPrivate(j,\"state\",@streamClosed)}if(!_.pull){w(B);return}if(!@isCallable(_.pull))w(B),@throwTypeError(\"pull is not a function\");@putByIdDirectPrivate(B,\"readableStreamController\",v);const f=@getByIdDirectPrivate(B,\"highWaterMark\");v.start({highWaterMark:!f||f<64\?64:f}),@startDirectStream.@call(v,B,_.pull,w),@putByIdDirectPrivate(B,\"reader\",{});var x=_.pull(v);if(v=@undefined,x&&@isPromise(x))return x.@then(()=>{})})\n";
+const char* const s_readableStreamInternalsReadDirectStreamCode = "(function (B,q,v){\"use strict\";@putByIdDirectPrivate(B,\"underlyingSource\",@undefined),@putByIdDirectPrivate(B,\"start\",@undefined);function w(f,A){var C=v\?.cancel;if(C){try{var j=C.@apply(v,A);if(@isPromise(j))@markPromiseAsHandled(j)}catch(x){}v=@undefined}if(f)if(@putByIdDirectPrivate(f,\"readableStreamController\",@undefined),@putByIdDirectPrivate(f,\"reader\",@undefined),A)@putByIdDirectPrivate(f,\"state\",@streamErrored),@putByIdDirectPrivate(f,\"storedError\",A);else @putByIdDirectPrivate(f,\"state\",@streamClosed)}if(!v.pull){w(B);return}if(!@isCallable(v.pull))w(B),@throwTypeError(\"pull is not a function\");@putByIdDirectPrivate(B,\"readableStreamController\",q);const _=@getByIdDirectPrivate(B,\"highWaterMark\");q.start({highWaterMark:!_||_<64\?64:_}),@startDirectStream.@call(q,B,v.pull,w),@putByIdDirectPrivate(B,\"reader\",{});var z=v.pull(q);if(q=@undefined,z&&@isPromise(z))return z.@then(()=>{})})\n";
// assignToStream
const JSC::ConstructAbility s_readableStreamInternalsAssignToStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1580,7 +1580,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadStreamIntoSinkCodeConstr
const JSC::ImplementationVisibility s_readableStreamInternalsReadStreamIntoSinkCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadStreamIntoSinkCodeLength = 1395;
static const JSC::Intrinsic s_readableStreamInternalsReadStreamIntoSinkCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadStreamIntoSinkCode = "(async function (_,c,f){\"use strict\";var I=!1,P=!1;try{var q=_.getReader(),x=q.readMany();if(x&&@isPromise(x))x=await x;if(x.done)return I=!0,c.end();var z=x.value.length;const J=@getByIdDirectPrivate(_,\"highWaterMark\");if(f)@startDirectStream.@call(c,_,@undefined,()=>!P&&@markPromiseAsHandled(_.cancel()));c.start({highWaterMark:J||0});for(var A=0,B=x.value,D=x.value.length;A<D;A++)c.write(B[A]);var E=@getByIdDirectPrivate(_,\"state\");if(E===@streamClosed)return I=!0,c.end();while(!0){var{value:F,done:G}=await q.read();if(G)return I=!0,c.end();c.write(F)}}catch(J){P=!0;try{q=@undefined;const K=_.cancel(J);@markPromiseAsHandled(K)}catch(K){}if(c&&!I){I=!0;try{c.close(J)}catch(K){throw new globalThis.AggregateError([J,K])}}throw J}finally{if(q){try{q.releaseLock()}catch(K){}q=@undefined}c=@undefined;var E=@getByIdDirectPrivate(_,\"state\");if(_){var H=@getByIdDirectPrivate(_,\"readableStreamController\");if(H){if(@getByIdDirectPrivate(H,\"underlyingSource\"))@putByIdDirectPrivate(H,\"underlyingSource\",@undefined);if(@getByIdDirectPrivate(H,\"controlledReadableStream\"))@putByIdDirectPrivate(H,\"controlledReadableStream\",@undefined);if(@putByIdDirectPrivate(_,\"readableStreamController\",null),@getByIdDirectPrivate(_,\"underlyingSource\"))@putByIdDirectPrivate(_,\"underlyingSource\",@undefined);H=@undefined}if(!P&&E!==@streamClosed&&E!==@streamErrored)@readableStreamClose(_);_=@undefined}}})\n";
+const char* const s_readableStreamInternalsReadStreamIntoSinkCode = "(async function (f,_,P){\"use strict\";var B=!1,q=!1;try{var E=f.getReader(),D=E.readMany();if(D&&@isPromise(D))D=await D;if(D.done)return B=!0,_.end();var F=D.value.length;const A=@getByIdDirectPrivate(f,\"highWaterMark\");if(P)@startDirectStream.@call(_,f,@undefined,()=>!q&&@markPromiseAsHandled(f.cancel()));_.start({highWaterMark:A||0});for(var G=0,H=D.value,J=D.value.length;G<J;G++)_.write(H[G]);var c=@getByIdDirectPrivate(f,\"state\");if(c===@streamClosed)return B=!0,_.end();while(!0){var{value:I,done:x}=await E.read();if(x)return B=!0,_.end();_.write(I)}}catch(A){q=!0;try{E=@undefined;const K=f.cancel(A);@markPromiseAsHandled(K)}catch(K){}if(_&&!B){B=!0;try{_.close(A)}catch(K){throw new globalThis.AggregateError([A,K])}}throw A}finally{if(E){try{E.releaseLock()}catch(K){}E=@undefined}_=@undefined;var c=@getByIdDirectPrivate(f,\"state\");if(f){var z=@getByIdDirectPrivate(f,\"readableStreamController\");if(z){if(@getByIdDirectPrivate(z,\"underlyingSource\"))@putByIdDirectPrivate(z,\"underlyingSource\",@undefined);if(@getByIdDirectPrivate(z,\"controlledReadableStream\"))@putByIdDirectPrivate(z,\"controlledReadableStream\",@undefined);if(@putByIdDirectPrivate(f,\"readableStreamController\",null),@getByIdDirectPrivate(f,\"underlyingSource\"))@putByIdDirectPrivate(f,\"underlyingSource\",@undefined);z=@undefined}if(!q&&c!==@streamClosed&&c!==@streamErrored)@readableStreamClose(f);f=@undefined}}})\n";
// handleDirectStreamError
const JSC::ConstructAbility s_readableStreamInternalsHandleDirectStreamErrorCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1604,7 +1604,7 @@ const JSC::ConstructorKind s_readableStreamInternalsOnPullDirectStreamCodeConstr
const JSC::ImplementationVisibility s_readableStreamInternalsOnPullDirectStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsOnPullDirectStreamCodeLength = 785;
static const JSC::Intrinsic s_readableStreamInternalsOnPullDirectStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsOnPullDirectStreamCode = "(function (g){\"use strict\";var h=g.@controlledReadableStream;if(!h||@getByIdDirectPrivate(h,\"state\")!==@streamReadable)return;if(g._deferClose===-1)return;g._deferClose=-1,g._deferFlush=-1;var i,y;try{var b=g.@underlyingSource.pull(g);if(b&&@isPromise(b)){if(g._handleError===@undefined)g._handleError=@handleDirectStreamErrorReject.bind(g);@Promise.prototype.catch.@call(b,g._handleError)}}catch(_){return @handleDirectStreamErrorReject.@call(g,_)}finally{i=g._deferClose,y=g._deferFlush,g._deferFlush=g._deferClose=0}var j;if(g._pendingRead===@undefined)g._pendingRead=j=@newPromise();else j=@readableStreamAddReadRequest(h);if(i===1){var k=g._deferCloseReason;return g._deferCloseReason=@undefined,@onCloseDirectStream.@call(g,k),j}if(y===1)@onFlushDirectStream.@call(g);return j})\n";
+const char* const s_readableStreamInternalsOnPullDirectStreamCode = "(function (h){\"use strict\";var b=h.@controlledReadableStream;if(!b||@getByIdDirectPrivate(b,\"state\")!==@streamReadable)return;if(h._deferClose===-1)return;h._deferClose=-1,h._deferFlush=-1;var j,y;try{var k=h.@underlyingSource.pull(h);if(k&&@isPromise(k)){if(h._handleError===@undefined)h._handleError=@handleDirectStreamErrorReject.bind(h);@Promise.prototype.catch.@call(k,h._handleError)}}catch(_){return @handleDirectStreamErrorReject.@call(h,_)}finally{j=h._deferClose,y=h._deferFlush,h._deferFlush=h._deferClose=0}var g;if(h._pendingRead===@undefined)h._pendingRead=g=@newPromise();else g=@readableStreamAddReadRequest(b);if(j===1){var i=h._deferCloseReason;return h._deferCloseReason=@undefined,@onCloseDirectStream.@call(h,i),g}if(y===1)@onFlushDirectStream.@call(h);return g})\n";
// noopDoneFunction
const JSC::ConstructAbility s_readableStreamInternalsNoopDoneFunctionCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1636,7 +1636,7 @@ const JSC::ConstructorKind s_readableStreamInternalsOnFlushDirectStreamCodeConst
const JSC::ImplementationVisibility s_readableStreamInternalsOnFlushDirectStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsOnFlushDirectStreamCodeLength = 591;
static const JSC::Intrinsic s_readableStreamInternalsOnFlushDirectStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsOnFlushDirectStreamCode = "(function (){\"use strict\";var c=this.@controlledReadableStream,B=@getByIdDirectPrivate(c,\"reader\");if(!B||!@isReadableStreamDefaultReader(B))return;var i=this._pendingRead;if(this._pendingRead=@undefined,i&&@isPromise(i)){var b=this.@sink.flush();if(b\?.byteLength)this._pendingRead=@getByIdDirectPrivate(c,\"readRequests\")\?.shift(),@fulfillPromise(i,{value:b,done:!1});else this._pendingRead=i}else if(@getByIdDirectPrivate(c,\"readRequests\")\?.isNotEmpty()){var b=this.@sink.flush();if(b\?.byteLength)@readableStreamFulfillReadRequest(c,b,!1)}else if(this._deferFlush===-1)this._deferFlush=1})\n";
+const char* const s_readableStreamInternalsOnFlushDirectStreamCode = "(function (){\"use strict\";var c=this.@controlledReadableStream,B=@getByIdDirectPrivate(c,\"reader\");if(!B||!@isReadableStreamDefaultReader(B))return;var b=this._pendingRead;if(this._pendingRead=@undefined,b&&@isPromise(b)){var i=this.@sink.flush();if(i\?.byteLength)this._pendingRead=@getByIdDirectPrivate(c,\"readRequests\")\?.shift(),@fulfillPromise(b,{value:i,done:!1});else this._pendingRead=b}else if(@getByIdDirectPrivate(c,\"readRequests\")\?.isNotEmpty()){var i=this.@sink.flush();if(i\?.byteLength)@readableStreamFulfillReadRequest(c,i,!1)}else if(this._deferFlush===-1)this._deferFlush=1})\n";
// createTextStream
const JSC::ConstructAbility s_readableStreamInternalsCreateTextStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1644,7 +1644,7 @@ const JSC::ConstructorKind s_readableStreamInternalsCreateTextStreamCodeConstruc
const JSC::ImplementationVisibility s_readableStreamInternalsCreateTextStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsCreateTextStreamCodeLength = 984;
static const JSC::Intrinsic s_readableStreamInternalsCreateTextStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsCreateTextStreamCode = "(function (v){\"use strict\";var x,z=[],A=!1,_=!1,E=\"\",q=@toLength(0),F=@newPromiseCapability(@Promise),G=!1;return x={start(){},write(w){if(typeof w===\"string\"){var C=@toLength(w.length);if(C>0)E+=w,A=!0,q+=C;return C}if(!w||!(@ArrayBuffer.@isView(w)||w instanceof @ArrayBuffer))@throwTypeError(\"Expected text, ArrayBuffer or ArrayBufferView\");const j=@toLength(w.byteLength);if(j>0)if(_=!0,E.length>0)@arrayPush(z,E,w),E=\"\";else @arrayPush(z,w);return q+=j,j},flush(){return 0},end(){if(G)return\"\";return x.fulfill()},fulfill(){G=!0;const w=x.finishInternal();return @fulfillPromise(F.@promise,w),w},finishInternal(){if(!A&&!_)return\"\";if(A&&!_)return E;if(_&&!A)return new globalThis.TextDecoder().decode(@Bun.concatArrayBuffers(z));var w=new @Bun.ArrayBufferSink;w.start({highWaterMark:q,asUint8Array:!0});for(let C of z)w.write(C);if(z.length=0,E.length>0)w.write(E),E=\"\";return new globalThis.TextDecoder().decode(w.end())},close(){try{if(!G)G=!0,x.fulfill()}catch(w){}}},[x,F]})\n";
+const char* const s_readableStreamInternalsCreateTextStreamCode = "(function (v){\"use strict\";var x,z=[],A=!1,j=!1,E=\"\",q=@toLength(0),F=@newPromiseCapability(@Promise),G=!1;return x={start(){},write(w){if(typeof w===\"string\"){var C=@toLength(w.length);if(C>0)E+=w,A=!0,q+=C;return C}if(!w||!(@ArrayBuffer.@isView(w)||w instanceof @ArrayBuffer))@throwTypeError(\"Expected text, ArrayBuffer or ArrayBufferView\");const _=@toLength(w.byteLength);if(_>0)if(j=!0,E.length>0)@arrayPush(z,E,w),E=\"\";else @arrayPush(z,w);return q+=_,_},flush(){return 0},end(){if(G)return\"\";return x.fulfill()},fulfill(){G=!0;const w=x.finishInternal();return @fulfillPromise(F.@promise,w),w},finishInternal(){if(!A&&!j)return\"\";if(A&&!j)return E;if(j&&!A)return new globalThis.TextDecoder().decode(@Bun.concatArrayBuffers(z));var w=new @Bun.ArrayBufferSink;w.start({highWaterMark:q,asUint8Array:!0});for(let C of z)w.write(C);if(z.length=0,E.length>0)w.write(E),E=\"\";return new globalThis.TextDecoder().decode(w.end())},close(){try{if(!G)G=!0,x.fulfill()}catch(w){}}},[x,F]})\n";
// initializeTextStream
const JSC::ConstructAbility s_readableStreamInternalsInitializeTextStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1660,7 +1660,7 @@ const JSC::ConstructorKind s_readableStreamInternalsInitializeArrayStreamCodeCon
const JSC::ImplementationVisibility s_readableStreamInternalsInitializeArrayStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsInitializeArrayStreamCodeLength = 797;
static const JSC::Intrinsic s_readableStreamInternalsInitializeArrayStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsInitializeArrayStreamCode = "(function (t,p){\"use strict\";var _=[],b=@newPromiseCapability(@Promise),d=!1;function j(){return d=!0,b.@resolve.@call(@undefined,_),_}var m={start(){},write(v){return @arrayPush(_,v),v.byteLength||v.length},flush(){return 0},end(){if(d)return[];return j()},close(){if(!d)j()}},q={@underlyingSource:t,@pull:@onPullDirectStream,@controlledReadableStream:this,@sink:m,close:@onCloseDirectStream,write:m.write,error:@handleDirectStreamError,end:@onCloseDirectStream,@close:@onCloseDirectStream,flush:@onFlushDirectStream,_pendingRead:@undefined,_deferClose:0,_deferFlush:0,_deferCloseReason:@undefined,_handleError:@undefined};return @putByIdDirectPrivate(this,\"readableStreamController\",q),@putByIdDirectPrivate(this,\"underlyingSource\",@undefined),@putByIdDirectPrivate(this,\"start\",@undefined),b})\n";
+const char* const s_readableStreamInternalsInitializeArrayStreamCode = "(function (_,t){\"use strict\";var p=[],b=@newPromiseCapability(@Promise),d=!1;function j(){return d=!0,b.@resolve.@call(@undefined,p),p}var m={start(){},write(v){return @arrayPush(p,v),v.byteLength||v.length},flush(){return 0},end(){if(d)return[];return j()},close(){if(!d)j()}},q={@underlyingSource:_,@pull:@onPullDirectStream,@controlledReadableStream:this,@sink:m,close:@onCloseDirectStream,write:m.write,error:@handleDirectStreamError,end:@onCloseDirectStream,@close:@onCloseDirectStream,flush:@onFlushDirectStream,_pendingRead:@undefined,_deferClose:0,_deferFlush:0,_deferCloseReason:@undefined,_handleError:@undefined};return @putByIdDirectPrivate(this,\"readableStreamController\",q),@putByIdDirectPrivate(this,\"underlyingSource\",@undefined),@putByIdDirectPrivate(this,\"start\",@undefined),b})\n";
// initializeArrayBufferStream
const JSC::ConstructAbility s_readableStreamInternalsInitializeArrayBufferStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1692,7 +1692,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamDefaultControl
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamDefaultControllerCallPullIfNeededCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamDefaultControllerCallPullIfNeededCodeLength = 859;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamDefaultControllerCallPullIfNeededCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamDefaultControllerCallPullIfNeededCode = "(function (i){\"use strict\";const _=@getByIdDirectPrivate(i,\"controlledReadableStream\");if(!@readableStreamDefaultControllerCanCloseOrEnqueue(i))return;if(@getByIdDirectPrivate(i,\"started\")!==1)return;if((!@isReadableStreamLocked(_)||!@getByIdDirectPrivate(@getByIdDirectPrivate(_,\"reader\"),\"readRequests\")\?.isNotEmpty())&&@readableStreamDefaultControllerGetDesiredSize(i)<=0)return;if(@getByIdDirectPrivate(i,\"pulling\")){@putByIdDirectPrivate(i,\"pullAgain\",!0);return}@assert(!@getByIdDirectPrivate(i,\"pullAgain\")),@putByIdDirectPrivate(i,\"pulling\",!0),@getByIdDirectPrivate(i,\"pullAlgorithm\").@call(@undefined).@then(function(){if(@putByIdDirectPrivate(i,\"pulling\",!1),@getByIdDirectPrivate(i,\"pullAgain\"))@putByIdDirectPrivate(i,\"pullAgain\",!1),@readableStreamDefaultControllerCallPullIfNeeded(i)},function(d){@readableStreamDefaultControllerError(i,d)})})\n";
+const char* const s_readableStreamInternalsReadableStreamDefaultControllerCallPullIfNeededCode = "(function (i){\"use strict\";const d=@getByIdDirectPrivate(i,\"controlledReadableStream\");if(!@readableStreamDefaultControllerCanCloseOrEnqueue(i))return;if(@getByIdDirectPrivate(i,\"started\")!==1)return;if((!@isReadableStreamLocked(d)||!@getByIdDirectPrivate(@getByIdDirectPrivate(d,\"reader\"),\"readRequests\")\?.isNotEmpty())&&@readableStreamDefaultControllerGetDesiredSize(i)<=0)return;if(@getByIdDirectPrivate(i,\"pulling\")){@putByIdDirectPrivate(i,\"pullAgain\",!0);return}@assert(!@getByIdDirectPrivate(i,\"pullAgain\")),@putByIdDirectPrivate(i,\"pulling\",!0),@getByIdDirectPrivate(i,\"pullAlgorithm\").@call(@undefined).@then(function(){if(@putByIdDirectPrivate(i,\"pulling\",!1),@getByIdDirectPrivate(i,\"pullAgain\"))@putByIdDirectPrivate(i,\"pullAgain\",!1),@readableStreamDefaultControllerCallPullIfNeeded(i)},function(_){@readableStreamDefaultControllerError(i,_)})})\n";
// isReadableStreamLocked
const JSC::ConstructAbility s_readableStreamInternalsIsReadableStreamLockedCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1724,7 +1724,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamCancelCodeCons
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamCancelCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamCancelCodeLength = 533;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamCancelCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamCancelCode = "(function (_,j){\"use strict\";@putByIdDirectPrivate(_,\"disturbed\",!0);const i=@getByIdDirectPrivate(_,\"state\");if(i===@streamClosed)return @Promise.@resolve();if(i===@streamErrored)return @Promise.@reject(@getByIdDirectPrivate(_,\"storedError\"));@readableStreamClose(_);var h=@getByIdDirectPrivate(_,\"readableStreamController\"),p=h.@cancel;if(p)return p(h,j).@then(function(){});var d=h.close;if(d)return @Promise.@resolve(h.close(j));return @Promise.@reject(@makeTypeError(\"ReadableStreamController has no cancel or close method\"))})\n";
+const char* const s_readableStreamInternalsReadableStreamCancelCode = "(function (_,d){\"use strict\";@putByIdDirectPrivate(_,\"disturbed\",!0);const h=@getByIdDirectPrivate(_,\"state\");if(h===@streamClosed)return @Promise.@resolve();if(h===@streamErrored)return @Promise.@reject(@getByIdDirectPrivate(_,\"storedError\"));@readableStreamClose(_);var j=@getByIdDirectPrivate(_,\"readableStreamController\"),p=j.@cancel;if(p)return p(j,d).@then(function(){});var i=j.close;if(i)return @Promise.@resolve(j.close(d));return @Promise.@reject(@makeTypeError(\"ReadableStreamController has no cancel or close method\"))})\n";
// readableStreamDefaultControllerCancel
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamDefaultControllerCancelCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1740,7 +1740,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamDefaultControl
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamDefaultControllerPullCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamDefaultControllerPullCodeLength = 519;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamDefaultControllerPullCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamDefaultControllerPullCode = "(function (a){\"use strict\";var d=@getByIdDirectPrivate(a,\"queue\");if(d.content.isNotEmpty()){const f=@dequeueValue(d);if(@getByIdDirectPrivate(a,\"closeRequested\")&&d.content.isEmpty())@readableStreamClose(@getByIdDirectPrivate(a,\"controlledReadableStream\"));else @readableStreamDefaultControllerCallPullIfNeeded(a);return @createFulfilledPromise({value:f,done:!1})}const _=@readableStreamAddReadRequest(@getByIdDirectPrivate(a,\"controlledReadableStream\"));return @readableStreamDefaultControllerCallPullIfNeeded(a),_})\n";
+const char* const s_readableStreamInternalsReadableStreamDefaultControllerPullCode = "(function (a){\"use strict\";var _=@getByIdDirectPrivate(a,\"queue\");if(_.content.isNotEmpty()){const f=@dequeueValue(_);if(@getByIdDirectPrivate(a,\"closeRequested\")&&_.content.isEmpty())@readableStreamClose(@getByIdDirectPrivate(a,\"controlledReadableStream\"));else @readableStreamDefaultControllerCallPullIfNeeded(a);return @createFulfilledPromise({value:f,done:!1})}const d=@readableStreamAddReadRequest(@getByIdDirectPrivate(a,\"controlledReadableStream\"));return @readableStreamDefaultControllerCallPullIfNeeded(a),d})\n";
// readableStreamDefaultControllerClose
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamDefaultControllerCloseCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1820,7 +1820,7 @@ const JSC::ConstructorKind s_readableStreamInternalsLazyLoadStreamCodeConstructo
const JSC::ImplementationVisibility s_readableStreamInternalsLazyLoadStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsLazyLoadStreamCodeLength = 1589;
static const JSC::Intrinsic s_readableStreamInternalsLazyLoadStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsLazyLoadStreamCode = "(function (Q,G){\"use strict\";var H=@getByIdDirectPrivate(Q,\"bunNativeType\"),I=@getByIdDirectPrivate(Q,\"bunNativePtr\"),J=@lazyStreamPrototypeMap.@get(H);if(J===@undefined){let j=function(D){var{c:p,v:z}=this;this.c=@undefined,this.v=@undefined,X(D,p,z)},N=function(D){try{D.close()}catch(p){globalThis.reportError(p)}},_=function(D,p,z,A){A[0]=!1;var E;try{E=b(D,z,A)}catch(F){return p.error(F)}return X(E,p,z)};var f=j,P=N,q=_,[b,m,K,x,L,O,U]=@lazyLoad(H),W=[!1],X;X=function D(p,z,A){if(p&&@isPromise(p))return p.then(j.bind({c:z,v:A}),(E)=>z.error(E));else if(typeof p===\"number\")if(A&&A.byteLength===p&&A.buffer===z.byobRequest\?.view\?.buffer)z.byobRequest.respondWithNewView(A);else z.byobRequest.respond(p);else if(p.constructor===@Uint8Array)z.enqueue(p);if(W[0]||p===!1)@enqueueJob(N,z),W[0]=!1};const B=L\?new FinalizationRegistry(L):null;J=class D{constructor(p,z,A){if(this.#f=p,this.#b={},this.pull=this.#j.bind(this),this.cancel=this.#m.bind(this),this.autoAllocateChunkSize=z,A!==@undefined)this.start=(E)=>{E.enqueue(A)};if(B)B.register(this,p,this.#b)}#b;pull;cancel;start;#f;type=\"bytes\";autoAllocateChunkSize=0;static startSync=m;#j(p){var z=this.#f;if(!z){p.close();return}_(z,p,p.byobRequest.view,W)}#m(p){var z=this.#f;B&&B.unregister(this.#b),O&&O(z,!1),K(z,p)}static deinit=L;static drain=U},@lazyStreamPrototypeMap.@set(H,J)}const Y=J.startSync(I,G);var Z;const{drain:y,deinit:M}=J;if(y)Z=y(I);if(Y===0){if(L&&I&&@enqueueJob(L,I),(Z\?.byteLength\?\?0)>0)return{start(j){j.enqueue(Z),j.close()},type:\"bytes\"};return{start(j){j.close()},type:\"bytes\"}}return new J(I,Y,Z)})\n";
+const char* const s_readableStreamInternalsLazyLoadStreamCode = "(function (Q,G){\"use strict\";var N=@getByIdDirectPrivate(Q,\"bunNativeType\"),H=@getByIdDirectPrivate(Q,\"bunNativePtr\"),I=@lazyStreamPrototypeMap.@get(N);if(I===@undefined){let m=function(D){var{c:p,v:z}=this;this.c=@undefined,this.v=@undefined,X(D,p,z)},M=function(D){try{D.close()}catch(p){globalThis.reportError(p)}},_=function(D,p,z,A){A[0]=!1;var E;try{E=f(D,z,A)}catch(F){return p.error(F)}return X(E,p,z)};var j=m,P=M,q=_,[f,b,J,x,K,O,U]=@lazyLoad(N),W=[!1],X;X=function D(p,z,A){if(p&&@isPromise(p))return p.then(m.bind({c:z,v:A}),(E)=>z.error(E));else if(typeof p===\"number\")if(A&&A.byteLength===p&&A.buffer===z.byobRequest\?.view\?.buffer)z.byobRequest.respondWithNewView(A);else z.byobRequest.respond(p);else if(p.constructor===@Uint8Array)z.enqueue(p);if(W[0]||p===!1)@enqueueJob(M,z),W[0]=!1};const B=K\?new FinalizationRegistry(K):null;I=class D{constructor(p,z,A){if(this.#f=p,this.#b={},this.pull=this.#j.bind(this),this.cancel=this.#m.bind(this),this.autoAllocateChunkSize=z,A!==@undefined)this.start=(E)=>{E.enqueue(A)};if(B)B.register(this,p,this.#b)}#b;pull;cancel;start;#f;type=\"bytes\";autoAllocateChunkSize=0;static startSync=b;#j(p){var z=this.#f;if(!z){p.close();return}_(z,p,p.byobRequest.view,W)}#m(p){var z=this.#f;B&&B.unregister(this.#b),O&&O(z,!1),J(z,p)}static deinit=K;static drain=U},@lazyStreamPrototypeMap.@set(N,I)}const Y=I.startSync(H,G);var Z;const{drain:y,deinit:L}=I;if(y)Z=y(H);if(Y===0){if(K&&H&&@enqueueJob(K,H),(Z\?.byteLength\?\?0)>0)return{start(m){m.enqueue(Z),m.close()},type:\"bytes\"};return{start(m){m.close()},type:\"bytes\"}}return new I(H,Y,Z)})\n";
// readableStreamIntoArray
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamIntoArrayCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1828,7 +1828,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamIntoArrayCodeC
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamIntoArrayCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamIntoArrayCodeLength = 247;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamIntoArrayCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamIntoArrayCode = "(function (f){\"use strict\";var _=f.getReader(),b=_.readMany();async function g(j){if(j.done)return[];var p=j.value||[];while(!0){var q=await _.read();if(q.done)break;p=p.concat(q.value)}return p}if(b&&@isPromise(b))return b.@then(g);return g(b)})\n";
+const char* const s_readableStreamInternalsReadableStreamIntoArrayCode = "(function (_){\"use strict\";var b=_.getReader(),g=b.readMany();async function j(q){if(q.done)return[];var f=q.value||[];while(!0){var p=await b.read();if(p.done)break;f=f.concat(p.value)}return f}if(g&&@isPromise(g))return g.@then(j);return j(g)})\n";
// readableStreamIntoText
const JSC::ConstructAbility s_readableStreamInternalsReadableStreamIntoTextCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -1868,7 +1868,7 @@ const JSC::ConstructorKind s_readableStreamInternalsReadableStreamDefineLazyIter
const JSC::ImplementationVisibility s_readableStreamInternalsReadableStreamDefineLazyIteratorsCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamInternalsReadableStreamDefineLazyIteratorsCodeLength = 516;
static const JSC::Intrinsic s_readableStreamInternalsReadableStreamDefineLazyIteratorsCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamInternalsReadableStreamDefineLazyIteratorsCode = "(function (g){\"use strict\";var w=globalThis.Symbol.asyncIterator,h=async function*z(i,B){var D=i.getReader(),j;try{while(!0){var F,G;const q=D.readMany();if(@isPromise(q))({done:F,value:G}=await q);else({done:F,value:G}=q);if(F)return;yield*G}}catch(q){j=q}finally{if(D.releaseLock(),!B)i.cancel(j);if(j)throw j}},x=function z(){return h(this,!1)},k=function z({preventCancel:i=!1}={preventCancel:!1}){return h(this,i)};return @Object.@defineProperty(g,w,{value:x}),@Object.@defineProperty(g,\"values\",{value:k}),g})\n";
+const char* const s_readableStreamInternalsReadableStreamDefineLazyIteratorsCode = "(function (h){\"use strict\";var g=globalThis.Symbol.asyncIterator,z=async function*j(D,q){var F=D.getReader(),w;try{while(!0){var G,x;const k=F.readMany();if(@isPromise(k))({done:G,value:x}=await k);else({done:G,value:x}=k);if(G)return;yield*x}}catch(k){w=k}finally{if(F.releaseLock(),!q)D.cancel(w);if(w)throw w}},i=function j(){return z(this,!1)},B=function j({preventCancel:D=!1}={preventCancel:!1}){return z(this,D)};return @Object.@defineProperty(h,g,{value:i}),@Object.@defineProperty(h,\"values\",{value:B}),h})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \
@@ -1934,9 +1934,9 @@ WEBCORE_FOREACH_TRANSFORMSTREAMDEFAULTCONTROLLER_BUILTIN_CODE(DEFINE_BUILTIN_GEN
const JSC::ConstructAbility s_eventStreamGetEventStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
const JSC::ConstructorKind s_eventStreamGetEventStreamCodeConstructorKind = JSC::ConstructorKind::None;
const JSC::ImplementationVisibility s_eventStreamGetEventStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
-const int s_eventStreamGetEventStreamCodeLength = 1504;
+const int s_eventStreamGetEventStreamCodeLength = 1429;
static const JSC::Intrinsic s_eventStreamGetEventStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_eventStreamGetEventStreamCode = "(function (){\"use strict\";class _ extends @ReadableStream{#_;@contentType=\"text/event-stream\";constructor(j){if(!j||!@isCallable(j.start))@throwTypeError(\"EventStream requires an object with `start`\");var y=[];super({type:\"direct\",pull:(g)=>{if(this.#_=g,y.length){for(let k of y)if(g.write(k),k===null){g.close(),this.#_=null;return}g.flush()}j.start\?.(this)},cancel:()=>{j.cancel\?.(this),this.#_=null}});this.#_={write:(g)=>y.push(g),flush:()=>{},close:()=>{y.push(null)}}}setReconnectionTime(j){var y=this.#_;if(!y)throw new Error(\"EventStream is closed\");y.write(\"retry:\"+j+\"\\n\\n\")}send(j,y,g){var k=this.#_;if(!k)throw new Error(\"EventStream is closed\");if(!y)y=j,j=@undefined;else if(j===\"message\")j=@undefined;if(y===@undefined)@throwTypeError(\"EventStream.send() requires a data argument\");if(g!==@undefined)this.#j(k,j,y,g);else this.#$(k,j,y);k.flush()}#$(j,y,g){if(y)j.write(\"event:\"+y+\"\\n\");if(typeof g===\"string\")j.write(\"data:\"+g.replace(/\\n/g,\"\\ndata:\")+\"\\n\\n\");else if(@isTypedArrayView(g)||g instanceof @ArrayBuffer)j.write(\"data:\"),j.write(g),j.write(\"\\n\\n\");else j.write(\"data:\"+JSON.stringify(g)+\"\\n\\n\")}#j(j,y,g,k){if(y)j.write(\"event:\"+y+\"\\n\");if(typeof g===\"string\")j.write(\"data:\"+g.replace(/\\n/g,\"\\ndata:\")+\"\\n\");else if(g instanceof @Uint8Array)j.write(\"data:\"),j.write(g),j.write(\"\\n\");else j.write(\"data:\"+JSON.stringify(g)+\"\\n\");if(k===null)j.write(\"id\\n\");else j.write(\"id:\"+k+\"\\n\")}close(){this.#_\?.close()}}return Object.defineProperty(_,\"name\",{value:\"EventStream\"}),_})\n";
+const char* const s_eventStreamGetEventStreamCode = "(function (){\"use strict\";class g extends @ReadableStream{#$;@contentType=\"text/event-stream\";constructor(D){var R=[],_=!1;super({type:\"direct\",pull:(j)=>{if(this.#$=j,R.length){for(let k of R)if(j.write(k),k===null){j.close(),this.#$=null;return}j.flush()}D\?.start\?.(this),_=!0},cancel:()=>{if(_)D\?.cancel\?.(this);this.#$=null}});this.#$={write:(j)=>R.push(j),flush:()=>{},close:()=>{R.push(null)}}}setReconnectionTime(D){var R=this.#$;if(!R)throw new Error(\"EventStream is closed\");R.write(\"retry:\"+D+\"\\n\\n\")}send(D,R,_){var j=this.#$;if(!j)throw new Error(\"EventStream is closed\");if(!R)R=D,D=@undefined;else if(D===\"message\")D=@undefined;if(R===@undefined)@throwTypeError(\"EventStream.send() requires a data argument\");if(_!==@undefined)this.#D(j,D,R,_);else this.#g(j,D,R);j.flush()}#g(D,R,_){if(R)D.write(\"event:\"+R+\"\\n\");if(typeof _===\"string\")D.write(\"data:\"+_.replace(/\\n/g,\"\\ndata:\")+\"\\n\\n\");else if(@isTypedArrayView(_)||_ instanceof @ArrayBuffer)D.write(\"data:\"),D.write(_),D.write(\"\\n\\n\");else D.write(\"data:\"+JSON.stringify(_)+\"\\n\\n\")}#D(D,R,_,j){if(R)D.write(\"event:\"+R+\"\\n\");if(typeof _===\"string\")D.write(\"data:\"+_.replace(/\\n/g,\"\\ndata:\")+\"\\n\");else if(_ instanceof @Uint8Array)D.write(\"data:\"),D.write(_),D.write(\"\\n\");else D.write(\"data:\"+JSON.stringify(_)+\"\\n\");if(j===null)D.write(\"id\\n\");else D.write(\"id:\"+j+\"\\n\")}close(){this.#$\?.close()}}return Object.defineProperty(g,\"name\",{value:\"EventStream\"}),g})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \
@@ -2038,7 +2038,7 @@ const JSC::ConstructorKind s_readableStreamDefaultReaderReadManyCodeConstructorK
const JSC::ImplementationVisibility s_readableStreamDefaultReaderReadManyCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamDefaultReaderReadManyCodeLength = 2598;
static const JSC::Intrinsic s_readableStreamDefaultReaderReadManyCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamDefaultReaderReadManyCode = "(function (){\"use strict\";if(!@isReadableStreamDefaultReader(this))@throwTypeError(\"ReadableStreamDefaultReader.readMany() should not be called directly\");const D=@getByIdDirectPrivate(this,\"ownerReadableStream\");if(!D)@throwTypeError(\"readMany() called on a reader owned by no readable stream\");const B=@getByIdDirectPrivate(D,\"state\");if(@putByIdDirectPrivate(D,\"disturbed\",!0),B===@streamClosed)return{value:[],size:0,done:!0};else if(B===@streamErrored)throw @getByIdDirectPrivate(D,\"storedError\");var I=@getByIdDirectPrivate(D,\"readableStreamController\"),j=@getByIdDirectPrivate(I,\"queue\");if(!j)return I.@pull(I).@then(function({done:H,value:w}){return H\?{done:!0,value:[],size:0}:{value:[w],size:1,done:!1}});const k=j.content;var E=j.size,F=k.toArray(!1),G=F.length;if(G>0){var _=@newArrayWithSize(G);if(@isReadableByteStreamController(I)){{const H=F[0];if(!(@ArrayBuffer.@isView(H)||H instanceof @ArrayBuffer))@putByValDirect(_,0,new @Uint8Array(H.buffer,H.byteOffset,H.byteLength));else @putByValDirect(_,0,H)}for(var x=1;x<G;x++){const H=F[x];if(!(@ArrayBuffer.@isView(H)||H instanceof @ArrayBuffer))@putByValDirect(_,x,new @Uint8Array(H.buffer,H.byteOffset,H.byteLength));else @putByValDirect(_,x,H)}}else{@putByValDirect(_,0,F[0].value);for(var x=1;x<G;x++)@putByValDirect(_,x,F[x].value)}if(@resetQueue(@getByIdDirectPrivate(I,\"queue\")),@getByIdDirectPrivate(I,\"closeRequested\"))@readableStreamClose(@getByIdDirectPrivate(I,\"controlledReadableStream\"));else if(@isReadableStreamDefaultController(I))@readableStreamDefaultControllerCallPullIfNeeded(I);else if(@isReadableByteStreamController(I))@readableByteStreamControllerCallPullIfNeeded(I);return{value:_,size:E,done:!1}}var A=(H)=>{if(H.done)return{value:[],size:0,done:!0};var w=@getByIdDirectPrivate(D,\"readableStreamController\"),J=@getByIdDirectPrivate(w,\"queue\"),K=[H.value].concat(J.content.toArray(!1)),N=K.length;if(@isReadableByteStreamController(w))for(var O=0;O<N;O++){const Q=K[O];if(!(@ArrayBuffer.@isView(Q)||Q instanceof @ArrayBuffer)){const{buffer:S,byteOffset:T,byteLength:U}=Q;@putByValDirect(K,O,new @Uint8Array(S,T,U))}}else for(var O=1;O<N;O++)@putByValDirect(K,O,K[O].value);var d=J.size;if(@resetQueue(J),@getByIdDirectPrivate(w,\"closeRequested\"))@readableStreamClose(@getByIdDirectPrivate(w,\"controlledReadableStream\"));else if(@isReadableStreamDefaultController(w))@readableStreamDefaultControllerCallPullIfNeeded(w);else if(@isReadableByteStreamController(w))@readableByteStreamControllerCallPullIfNeeded(w);return{value:K,size:d,done:!1}},C=I.@pull(I);if(C&&@isPromise(C))return C.@then(A);return A(C)})\n";
+const char* const s_readableStreamDefaultReaderReadManyCode = "(function (){\"use strict\";if(!@isReadableStreamDefaultReader(this))@throwTypeError(\"ReadableStreamDefaultReader.readMany() should not be called directly\");const S=@getByIdDirectPrivate(this,\"ownerReadableStream\");if(!S)@throwTypeError(\"readMany() called on a reader owned by no readable stream\");const C=@getByIdDirectPrivate(S,\"state\");if(@putByIdDirectPrivate(S,\"disturbed\",!0),C===@streamClosed)return{value:[],size:0,done:!0};else if(C===@streamErrored)throw @getByIdDirectPrivate(S,\"storedError\");var K=@getByIdDirectPrivate(S,\"readableStreamController\"),D=@getByIdDirectPrivate(K,\"queue\");if(!D)return K.@pull(K).@then(function({done:O,value:B}){return O\?{done:!0,value:[],size:0}:{value:[B],size:1,done:!1}});const E=D.content;var d=D.size,_=E.toArray(!1),F=_.length;if(F>0){var x=@newArrayWithSize(F);if(@isReadableByteStreamController(K)){{const O=_[0];if(!(@ArrayBuffer.@isView(O)||O instanceof @ArrayBuffer))@putByValDirect(x,0,new @Uint8Array(O.buffer,O.byteOffset,O.byteLength));else @putByValDirect(x,0,O)}for(var N=1;N<F;N++){const O=_[N];if(!(@ArrayBuffer.@isView(O)||O instanceof @ArrayBuffer))@putByValDirect(x,N,new @Uint8Array(O.buffer,O.byteOffset,O.byteLength));else @putByValDirect(x,N,O)}}else{@putByValDirect(x,0,_[0].value);for(var N=1;N<F;N++)@putByValDirect(x,N,_[N].value)}if(@resetQueue(@getByIdDirectPrivate(K,\"queue\")),@getByIdDirectPrivate(K,\"closeRequested\"))@readableStreamClose(@getByIdDirectPrivate(K,\"controlledReadableStream\"));else if(@isReadableStreamDefaultController(K))@readableStreamDefaultControllerCallPullIfNeeded(K);else if(@isReadableByteStreamController(K))@readableByteStreamControllerCallPullIfNeeded(K);return{value:x,size:d,done:!1}}var T=(O)=>{if(O.done)return{value:[],size:0,done:!0};var B=@getByIdDirectPrivate(S,\"readableStreamController\"),w=@getByIdDirectPrivate(B,\"queue\"),G=[O.value].concat(w.content.toArray(!1)),A=G.length;if(@isReadableByteStreamController(B))for(var H=0;H<A;H++){const I=G[H];if(!(@ArrayBuffer.@isView(I)||I instanceof @ArrayBuffer)){const{buffer:Q,byteOffset:j,byteLength:J}=I;@putByValDirect(G,H,new @Uint8Array(Q,j,J))}}else for(var H=1;H<A;H++)@putByValDirect(G,H,G[H].value);var k=w.size;if(@resetQueue(w),@getByIdDirectPrivate(B,\"closeRequested\"))@readableStreamClose(@getByIdDirectPrivate(B,\"controlledReadableStream\"));else if(@isReadableStreamDefaultController(B))@readableStreamDefaultControllerCallPullIfNeeded(B);else if(@isReadableByteStreamController(B))@readableByteStreamControllerCallPullIfNeeded(B);return{value:G,size:k,done:!1}},U=K.@pull(K);if(U&&@isPromise(U))return U.@then(T);return T(U)})\n";
// read
const JSC::ConstructAbility s_readableStreamDefaultReaderReadCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2112,7 +2112,7 @@ const JSC::ConstructorKind s_streamInternalsPromiseInvokeOrNoopMethodCodeConstru
const JSC::ImplementationVisibility s_streamInternalsPromiseInvokeOrNoopMethodCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_streamInternalsPromiseInvokeOrNoopMethodCodeLength = 122;
static const JSC::Intrinsic s_streamInternalsPromiseInvokeOrNoopMethodCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_streamInternalsPromiseInvokeOrNoopMethodCode = "(function (d,f,i){\"use strict\";try{return @promiseInvokeOrNoopMethodNoCatch(d,f,i)}catch(l){return @Promise.@reject(l)}})\n";
+const char* const s_streamInternalsPromiseInvokeOrNoopMethodCode = "(function (l,d,f){\"use strict\";try{return @promiseInvokeOrNoopMethodNoCatch(l,d,f)}catch(i){return @Promise.@reject(i)}})\n";
// promiseInvokeOrNoop
const JSC::ConstructAbility s_streamInternalsPromiseInvokeOrNoopCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2128,7 +2128,7 @@ const JSC::ConstructorKind s_streamInternalsPromiseInvokeOrFallbackOrNoopCodeCon
const JSC::ImplementationVisibility s_streamInternalsPromiseInvokeOrFallbackOrNoopCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_streamInternalsPromiseInvokeOrFallbackOrNoopCodeLength = 198;
static const JSC::Intrinsic s_streamInternalsPromiseInvokeOrFallbackOrNoopCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_streamInternalsPromiseInvokeOrFallbackOrNoopCode = "(function (n,_,p,u,l){\"use strict\";try{const v=n[_];if(v===@undefined)return @promiseInvokeOrNoopNoCatch(n,u,l);return @shieldingPromiseResolve(v.@apply(n,p))}catch(v){return @Promise.@reject(v)}})\n";
+const char* const s_streamInternalsPromiseInvokeOrFallbackOrNoopCode = "(function (_,l,p,u,v){\"use strict\";try{const n=_[l];if(n===@undefined)return @promiseInvokeOrNoopNoCatch(_,u,v);return @shieldingPromiseResolve(n.@apply(_,p))}catch(n){return @Promise.@reject(n)}})\n";
// validateAndNormalizeQueuingStrategy
const JSC::ConstructAbility s_streamInternalsValidateAndNormalizeQueuingStrategyCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2144,7 +2144,7 @@ const JSC::ConstructorKind s_streamInternalsCreateFIFOCodeConstructorKind = JSC:
const JSC::ImplementationVisibility s_streamInternalsCreateFIFOCodeImplementationVisibility = JSC::ImplementationVisibility::Private;
const int s_streamInternalsCreateFIFOCodeLength = 1472;
static const JSC::Intrinsic s_streamInternalsCreateFIFOCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_streamInternalsCreateFIFOCode = "(function (){\"use strict\";var x=@Array.prototype.slice;class b{constructor(){this._head=0,this._tail=0,this._capacityMask=3,this._list=@newArrayWithSize(4)}_head;_tail;_capacityMask;_list;size(){if(this._head===this._tail)return 0;if(this._head<this._tail)return this._tail-this._head;else return this._capacityMask+1-(this._head-this._tail)}isEmpty(){return this.size()==0}isNotEmpty(){return this.size()>0}shift(){var{_head:g,_tail:w,_list:k,_capacityMask:A}=this;if(g===w)return @undefined;var z=k[g];if(@putByValDirect(k,g,@undefined),g=this._head=g+1&A,g<2&&w>1e4&&w<=k.length>>>2)this._shrinkArray();return z}peek(){if(this._head===this._tail)return @undefined;return this._list[this._head]}push(g){var w=this._tail;if(@putByValDirect(this._list,w,g),this._tail=w+1&this._capacityMask,this._tail===this._head)this._growArray()}toArray(g){var w=this._list,k=@toLength(w.length);if(g||this._head>this._tail){var A=@toLength(this._head),z=@toLength(this._tail),B=@toLength(k-A+z),E=@newArrayWithSize(B),F=0;for(var G=A;G<k;G++)@putByValDirect(E,F++,w[G]);for(var G=0;G<z;G++)@putByValDirect(E,F++,w[G]);return E}else return x.@call(w,this._head,this._tail)}clear(){this._head=0,this._tail=0,this._list.fill(@undefined)}_growArray(){if(this._head)this._list=this.toArray(!0),this._head=0;this._tail=@toLength(this._list.length),this._list.length<<=1,this._capacityMask=this._capacityMask<<1|1}shrinkArray(){this._list.length>>>=1,this._capacityMask>>>=1}}return new b})\n";
+const char* const s_streamInternalsCreateFIFOCode = "(function (){\"use strict\";var v=@Array.prototype.slice;class k{constructor(){this._head=0,this._tail=0,this._capacityMask=3,this._list=@newArrayWithSize(4)}_head;_tail;_capacityMask;_list;size(){if(this._head===this._tail)return 0;if(this._head<this._tail)return this._tail-this._head;else return this._capacityMask+1-(this._head-this._tail)}isEmpty(){return this.size()==0}isNotEmpty(){return this.size()>0}shift(){var{_head:E,_tail:z,_list:x,_capacityMask:F}=this;if(E===z)return @undefined;var b=x[E];if(@putByValDirect(x,E,@undefined),E=this._head=E+1&F,E<2&&z>1e4&&z<=x.length>>>2)this._shrinkArray();return b}peek(){if(this._head===this._tail)return @undefined;return this._list[this._head]}push(E){var z=this._tail;if(@putByValDirect(this._list,z,E),this._tail=z+1&this._capacityMask,this._tail===this._head)this._growArray()}toArray(E){var z=this._list,x=@toLength(z.length);if(E||this._head>this._tail){var F=@toLength(this._head),b=@toLength(this._tail),A=@toLength(x-F+b),g=@newArrayWithSize(A),w=0;for(var G=F;G<x;G++)@putByValDirect(g,w++,z[G]);for(var G=0;G<b;G++)@putByValDirect(g,w++,z[G]);return g}else return v.@call(z,this._head,this._tail)}clear(){this._head=0,this._tail=0,this._list.fill(@undefined)}_growArray(){if(this._head)this._list=this.toArray(!0),this._head=0;this._tail=@toLength(this._list.length),this._list.length<<=1,this._capacityMask=this._capacityMask<<1|1}shrinkArray(){this._list.length>>>=1,this._capacityMask>>>=1}}return new k})\n";
// newQueue
const JSC::ConstructAbility s_streamInternalsNewQueueCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2160,7 +2160,7 @@ const JSC::ConstructorKind s_streamInternalsDequeueValueCodeConstructorKind = JS
const JSC::ImplementationVisibility s_streamInternalsDequeueValueCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_streamInternalsDequeueValueCodeLength = 106;
static const JSC::Intrinsic s_streamInternalsDequeueValueCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_streamInternalsDequeueValueCode = "(function (l){\"use strict\";const p=l.content.shift();if(l.size-=p.size,l.size<0)l.size=0;return p.value})\n";
+const char* const s_streamInternalsDequeueValueCode = "(function (p){\"use strict\";const l=p.content.shift();if(p.size-=l.size,p.size<0)p.size=0;return l.value})\n";
// enqueueValueWithSize
const JSC::ConstructAbility s_streamInternalsEnqueueValueWithSizeCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2266,7 +2266,7 @@ const JSC::ConstructorKind s_importMetaObjectCreateRequireCacheCodeConstructorKi
const JSC::ImplementationVisibility s_importMetaObjectCreateRequireCacheCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_importMetaObjectCreateRequireCacheCodeLength = 854;
static const JSC::Intrinsic s_importMetaObjectCreateRequireCacheCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_importMetaObjectCreateRequireCacheCode = "(function (){\"use strict\";var _=new Map,f={};return new Proxy(f,{get(h,t){const u=@requireMap.@get(t);if(u)return u;const L=@Loader.registry.@get(t);if(L\?.evaluated){const b=@Loader.getModuleNamespaceObject(L.module),c=b[@commonJSSymbol]===0||b.default\?.[@commonJSSymbol]\?b.default:b,g=@createCommonJSModule(t,c,!0);return @requireMap.@set(t,g),g}return f[t]},set(h,t,u){return @requireMap.@set(t,u),!0},has(h,t){return @requireMap.@has(t)||@Loader.registry.@has(t)},deleteProperty(h,t){return _.@delete(t),@requireMap.@delete(t),@Loader.registry.@delete(t),!0},ownKeys(h){var t=[...@requireMap.@keys()];const u=[...@Loader.registry.@keys()];for(let L of u)if(!t.includes(L))@arrayPush(t,L);return t},getPrototypeOf(h){return null},getOwnPropertyDescriptor(h,t){if(@requireMap.@has(t)||@Loader.registry.@has(t))return{configurable:!0,enumerable:!0}}})})\n";
+const char* const s_importMetaObjectCreateRequireCacheCode = "(function (){\"use strict\";var h=new Map,t={};return new Proxy(t,{get(u,L){const _=@requireMap.@get(L);if(_)return _;const b=@Loader.registry.@get(L);if(b\?.evaluated){const f=@Loader.getModuleNamespaceObject(b.module),c=f[@commonJSSymbol]===0||f.default\?.[@commonJSSymbol]\?f.default:f,g=@createCommonJSModule(L,c,!0);return @requireMap.@set(L,g),g}return t[L]},set(u,L,_){return @requireMap.@set(L,_),!0},has(u,L){return @requireMap.@has(L)||@Loader.registry.@has(L)},deleteProperty(u,L){return h.@delete(L),@requireMap.@delete(L),@Loader.registry.@delete(L),!0},ownKeys(u){var L=[...@requireMap.@keys()];const _=[...@Loader.registry.@keys()];for(let b of _)if(!L.includes(b))@arrayPush(L,b);return L},getPrototypeOf(u){return null},getOwnPropertyDescriptor(u,L){if(@requireMap.@has(L)||@Loader.registry.@has(L))return{configurable:!0,enumerable:!0}}})})\n";
// require
const JSC::ConstructAbility s_importMetaObjectRequireCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2376,7 +2376,7 @@ const JSC::ConstructorKind s_writableStreamDefaultWriterInitializeWritableStream
const JSC::ImplementationVisibility s_writableStreamDefaultWriterInitializeWritableStreamDefaultWriterCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_writableStreamDefaultWriterInitializeWritableStreamDefaultWriterCodeLength = 237;
static const JSC::Intrinsic s_writableStreamDefaultWriterInitializeWritableStreamDefaultWriterCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_writableStreamDefaultWriterInitializeWritableStreamDefaultWriterCode = "(function (u){\"use strict\";const c=@getInternalWritableStream(u);if(c)u=c;if(!@isWritableStream(u))@throwTypeError(\"WritableStreamDefaultWriter constructor takes a WritableStream\");return @setUpWritableStreamDefaultWriter(this,u),this})\n";
+const char* const s_writableStreamDefaultWriterInitializeWritableStreamDefaultWriterCode = "(function (c){\"use strict\";const u=@getInternalWritableStream(c);if(u)c=u;if(!@isWritableStream(c))@throwTypeError(\"WritableStreamDefaultWriter constructor takes a WritableStream\");return @setUpWritableStreamDefaultWriter(this,c),this})\n";
// closed
const JSC::ConstructAbility s_writableStreamDefaultWriterClosedCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2458,7 +2458,7 @@ const JSC::ConstructorKind s_readableStreamReadableStreamToArrayCodeConstructorK
const JSC::ImplementationVisibility s_readableStreamReadableStreamToArrayCodeImplementationVisibility = JSC::ImplementationVisibility::Private;
const int s_readableStreamReadableStreamToArrayCodeLength = 173;
static const JSC::Intrinsic s_readableStreamReadableStreamToArrayCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamReadableStreamToArrayCode = "(function (b){\"use strict\";var _=@getByIdDirectPrivate(b,\"underlyingSource\");if(_!==@undefined)return @readableStreamToArrayDirect(b,_);return @readableStreamIntoArray(b)})\n";
+const char* const s_readableStreamReadableStreamToArrayCode = "(function (_){\"use strict\";var b=@getByIdDirectPrivate(_,\"underlyingSource\");if(b!==@undefined)return @readableStreamToArrayDirect(_,b);return @readableStreamIntoArray(_)})\n";
// readableStreamToText
const JSC::ConstructAbility s_readableStreamReadableStreamToTextCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2498,7 +2498,7 @@ const JSC::ConstructorKind s_readableStreamConsumeReadableStreamCodeConstructorK
const JSC::ImplementationVisibility s_readableStreamConsumeReadableStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Private;
const int s_readableStreamConsumeReadableStreamCodeLength = 1603;
static const JSC::Intrinsic s_readableStreamConsumeReadableStreamCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamConsumeReadableStreamCode = "(function (_,w,x){\"use strict\";const A=globalThis.Symbol.for(\"Bun.consumeReadableStreamPrototype\");var B=globalThis[A];if(!B)B=globalThis[A]=[];var D=B[w];if(D===@undefined){var[F,G,H,j,I,J]=globalThis[globalThis.Symbol.for(\"Bun.lazy\")](w);D=class K{handleError;handleClosed;processResult;constructor(L,N){this.#_=N,this.#F=L,this.#$=!1,this.handleError=this._handleError.bind(this),this.handleClosed=this._handleClosed.bind(this),this.processResult=this._processResult.bind(this),L.closed.then(this.handleClosed,this.handleError)}_handleClosed(){if(this.#$)return;this.#$=!0;var L=this.#_;this.#_=0,j(L),J(L)}_handleError(L){if(this.#$)return;this.#$=!0;var N=this.#_;this.#_=0,G(N,L),J(N)}#_;#$=!1;#F;_handleReadMany({value:L,done:N,size:q}){if(N){this.handleClosed();return}if(this.#$)return;H(this.#_,L,N,q)}read(){if(!this.#_)return @throwTypeError(\"ReadableStreamSink is already closed\");return this.processResult(this.#F.read())}_processResult(L){if(L&&@isPromise(L)){if(@getPromiseInternalField(L,@promiseFieldFlags)&@promiseStateFulfilled){const q=@getPromiseInternalField(L,@promiseFieldReactionsOrResult);if(q)L=q}}if(L&&@isPromise(L))return L.then(this.processResult,this.handleError),null;if(L.done)return this.handleClosed(),0;else if(L.value)return L.value;else return-1}readMany(){if(!this.#_)return @throwTypeError(\"ReadableStreamSink is already closed\");return this.processResult(this.#F.readMany())}};const k=w+1;if(B.length<k)B.length=k;@putByValDirect(B,w,D)}if(@isReadableStreamLocked(x))@throwTypeError(\"Cannot start reading from a locked stream\");return new D(x.getReader(),_)})\n";
+const char* const s_readableStreamConsumeReadableStreamCode = "(function (_,I,K){\"use strict\";const F=globalThis.Symbol.for(\"Bun.consumeReadableStreamPrototype\");var j=globalThis[F];if(!j)j=globalThis[F]=[];var J=j[I];if(J===@undefined){var[k,L,q,w,x,N]=globalThis[globalThis.Symbol.for(\"Bun.lazy\")](I);J=class H{handleError;handleClosed;processResult;constructor(B,D){this.#_=D,this.#F=B,this.#$=!1,this.handleError=this._handleError.bind(this),this.handleClosed=this._handleClosed.bind(this),this.processResult=this._processResult.bind(this),B.closed.then(this.handleClosed,this.handleError)}_handleClosed(){if(this.#$)return;this.#$=!0;var B=this.#_;this.#_=0,w(B),N(B)}_handleError(B){if(this.#$)return;this.#$=!0;var D=this.#_;this.#_=0,L(D,B),N(D)}#_;#$=!1;#F;_handleReadMany({value:B,done:D,size:G}){if(D){this.handleClosed();return}if(this.#$)return;q(this.#_,B,D,G)}read(){if(!this.#_)return @throwTypeError(\"ReadableStreamSink is already closed\");return this.processResult(this.#F.read())}_processResult(B){if(B&&@isPromise(B)){if(@getPromiseInternalField(B,@promiseFieldFlags)&@promiseStateFulfilled){const G=@getPromiseInternalField(B,@promiseFieldReactionsOrResult);if(G)B=G}}if(B&&@isPromise(B))return B.then(this.processResult,this.handleError),null;if(B.done)return this.handleClosed(),0;else if(B.value)return B.value;else return-1}readMany(){if(!this.#_)return @throwTypeError(\"ReadableStreamSink is already closed\");return this.processResult(this.#F.readMany())}};const A=I+1;if(j.length<A)j.length=A;@putByValDirect(j,I,J)}if(@isReadableStreamLocked(K))@throwTypeError(\"Cannot start reading from a locked stream\");return new J(K.getReader(),_)})\n";
// createEmptyReadableStream
const JSC::ConstructAbility s_readableStreamCreateEmptyReadableStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2596,7 +2596,7 @@ const JSC::ConstructorKind s_readableStreamDefaultControllerInitializeReadableSt
const JSC::ImplementationVisibility s_readableStreamDefaultControllerInitializeReadableStreamDefaultControllerCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableStreamDefaultControllerInitializeReadableStreamDefaultControllerCodeLength = 263;
static const JSC::Intrinsic s_readableStreamDefaultControllerInitializeReadableStreamDefaultControllerCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableStreamDefaultControllerInitializeReadableStreamDefaultControllerCode = "(function (_,p,C,R){\"use strict\";if(arguments.length!==5&&arguments[4]!==@isReadableStream)@throwTypeError(\"ReadableStreamDefaultController constructor should not be called directly\");return @privateInitializeReadableStreamDefaultController.@call(this,_,p,C,R)})\n";
+const char* const s_readableStreamDefaultControllerInitializeReadableStreamDefaultControllerCode = "(function (_,p,R,C){\"use strict\";if(arguments.length!==5&&arguments[4]!==@isReadableStream)@throwTypeError(\"ReadableStreamDefaultController constructor should not be called directly\");return @privateInitializeReadableStreamDefaultController.@call(this,_,p,R,C)})\n";
// enqueue
const JSC::ConstructAbility s_readableStreamDefaultControllerEnqueueCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2646,7 +2646,7 @@ const JSC::ConstructorKind s_readableByteStreamInternalsPrivateInitializeReadabl
const JSC::ImplementationVisibility s_readableByteStreamInternalsPrivateInitializeReadableByteStreamControllerCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableByteStreamInternalsPrivateInitializeReadableByteStreamControllerCodeLength = 1654;
static const JSC::Intrinsic s_readableByteStreamInternalsPrivateInitializeReadableByteStreamControllerCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableByteStreamInternalsPrivateInitializeReadableByteStreamControllerCode = "(function (_,v,b){\"use strict\";if(!@isReadableStream(_))@throwTypeError(\"ReadableByteStreamController needs a ReadableStream\");if(@getByIdDirectPrivate(_,\"readableStreamController\")!==null)@throwTypeError(\"ReadableStream already has a controller\");@putByIdDirectPrivate(this,\"controlledReadableStream\",_),@putByIdDirectPrivate(this,\"underlyingByteSource\",v),@putByIdDirectPrivate(this,\"pullAgain\",!1),@putByIdDirectPrivate(this,\"pulling\",!1),@readableByteStreamControllerClearPendingPullIntos(this),@putByIdDirectPrivate(this,\"queue\",@newQueue()),@putByIdDirectPrivate(this,\"started\",0),@putByIdDirectPrivate(this,\"closeRequested\",!1);let p=@toNumber(b);if(@isNaN(p)||p<0)@throwRangeError(\"highWaterMark value is negative or not a number\");@putByIdDirectPrivate(this,\"strategyHWM\",p);let R=v.autoAllocateChunkSize;if(R!==@undefined){if(R=@toNumber(R),R<=0||R===@Infinity||R===-@Infinity)@throwRangeError(\"autoAllocateChunkSize value is negative or equal to positive or negative infinity\")}@putByIdDirectPrivate(this,\"autoAllocateChunkSize\",R),@putByIdDirectPrivate(this,\"pendingPullIntos\",@createFIFO());const d=this;return @promiseInvokeOrNoopNoCatch(@getByIdDirectPrivate(d,\"underlyingByteSource\"),\"start\",[d]).@then(()=>{@putByIdDirectPrivate(d,\"started\",1),@assert(!@getByIdDirectPrivate(d,\"pulling\")),@assert(!@getByIdDirectPrivate(d,\"pullAgain\")),@readableByteStreamControllerCallPullIfNeeded(d)},(f)=>{if(@getByIdDirectPrivate(_,\"state\")===@streamReadable)@readableByteStreamControllerError(d,f)}),@putByIdDirectPrivate(this,\"cancel\",@readableByteStreamControllerCancel),@putByIdDirectPrivate(this,\"pull\",@readableByteStreamControllerPull),this})\n";
+const char* const s_readableByteStreamInternalsPrivateInitializeReadableByteStreamControllerCode = "(function (_,v,b){\"use strict\";if(!@isReadableStream(_))@throwTypeError(\"ReadableByteStreamController needs a ReadableStream\");if(@getByIdDirectPrivate(_,\"readableStreamController\")!==null)@throwTypeError(\"ReadableStream already has a controller\");@putByIdDirectPrivate(this,\"controlledReadableStream\",_),@putByIdDirectPrivate(this,\"underlyingByteSource\",v),@putByIdDirectPrivate(this,\"pullAgain\",!1),@putByIdDirectPrivate(this,\"pulling\",!1),@readableByteStreamControllerClearPendingPullIntos(this),@putByIdDirectPrivate(this,\"queue\",@newQueue()),@putByIdDirectPrivate(this,\"started\",0),@putByIdDirectPrivate(this,\"closeRequested\",!1);let f=@toNumber(b);if(@isNaN(f)||f<0)@throwRangeError(\"highWaterMark value is negative or not a number\");@putByIdDirectPrivate(this,\"strategyHWM\",f);let p=v.autoAllocateChunkSize;if(p!==@undefined){if(p=@toNumber(p),p<=0||p===@Infinity||p===-@Infinity)@throwRangeError(\"autoAllocateChunkSize value is negative or equal to positive or negative infinity\")}@putByIdDirectPrivate(this,\"autoAllocateChunkSize\",p),@putByIdDirectPrivate(this,\"pendingPullIntos\",@createFIFO());const R=this;return @promiseInvokeOrNoopNoCatch(@getByIdDirectPrivate(R,\"underlyingByteSource\"),\"start\",[R]).@then(()=>{@putByIdDirectPrivate(R,\"started\",1),@assert(!@getByIdDirectPrivate(R,\"pulling\")),@assert(!@getByIdDirectPrivate(R,\"pullAgain\")),@readableByteStreamControllerCallPullIfNeeded(R)},(d)=>{if(@getByIdDirectPrivate(_,\"state\")===@streamReadable)@readableByteStreamControllerError(R,d)}),@putByIdDirectPrivate(this,\"cancel\",@readableByteStreamControllerCancel),@putByIdDirectPrivate(this,\"pull\",@readableByteStreamControllerPull),this})\n";
// readableStreamByteStreamControllerStart
const JSC::ConstructAbility s_readableByteStreamInternalsReadableStreamByteStreamControllerStartCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2758,7 +2758,7 @@ const JSC::ConstructorKind s_readableByteStreamInternalsReadableByteStreamContro
const JSC::ImplementationVisibility s_readableByteStreamInternalsReadableByteStreamControllerPullCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableByteStreamInternalsReadableByteStreamControllerPullCodeLength = 1005;
static const JSC::Intrinsic s_readableByteStreamInternalsReadableByteStreamControllerPullCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableByteStreamInternalsReadableByteStreamControllerPullCode = "(function (_){\"use strict\";const d=@getByIdDirectPrivate(_,\"controlledReadableStream\");if(@assert(@readableStreamHasDefaultReader(d)),@getByIdDirectPrivate(_,\"queue\").content\?.isNotEmpty()){const F=@getByIdDirectPrivate(_,\"queue\").content.shift();@getByIdDirectPrivate(_,\"queue\").size-=F.byteLength,@readableByteStreamControllerHandleQueueDrain(_);let P;try{P=new @Uint8Array(F.buffer,F.byteOffset,F.byteLength)}catch(R){return @Promise.@reject(R)}return @createFulfilledPromise({value:P,done:!1})}if(@getByIdDirectPrivate(_,\"autoAllocateChunkSize\")!==@undefined){let F;try{F=@createUninitializedArrayBuffer(@getByIdDirectPrivate(_,\"autoAllocateChunkSize\"))}catch(R){return @Promise.@reject(R)}const P={buffer:F,byteOffset:0,byteLength:@getByIdDirectPrivate(_,\"autoAllocateChunkSize\"),bytesFilled:0,elementSize:1,ctor:@Uint8Array,readerType:\"default\"};@getByIdDirectPrivate(_,\"pendingPullIntos\").push(P)}const h=@readableStreamAddReadRequest(d);return @readableByteStreamControllerCallPullIfNeeded(_),h})\n";
+const char* const s_readableByteStreamInternalsReadableByteStreamControllerPullCode = "(function (d){\"use strict\";const h=@getByIdDirectPrivate(d,\"controlledReadableStream\");if(@assert(@readableStreamHasDefaultReader(h)),@getByIdDirectPrivate(d,\"queue\").content\?.isNotEmpty()){const P=@getByIdDirectPrivate(d,\"queue\").content.shift();@getByIdDirectPrivate(d,\"queue\").size-=P.byteLength,@readableByteStreamControllerHandleQueueDrain(d);let R;try{R=new @Uint8Array(P.buffer,P.byteOffset,P.byteLength)}catch(_){return @Promise.@reject(_)}return @createFulfilledPromise({value:R,done:!1})}if(@getByIdDirectPrivate(d,\"autoAllocateChunkSize\")!==@undefined){let P;try{P=@createUninitializedArrayBuffer(@getByIdDirectPrivate(d,\"autoAllocateChunkSize\"))}catch(_){return @Promise.@reject(_)}const R={buffer:P,byteOffset:0,byteLength:@getByIdDirectPrivate(d,\"autoAllocateChunkSize\"),bytesFilled:0,elementSize:1,ctor:@Uint8Array,readerType:\"default\"};@getByIdDirectPrivate(d,\"pendingPullIntos\").push(R)}const F=@readableStreamAddReadRequest(h);return @readableByteStreamControllerCallPullIfNeeded(d),F})\n";
// readableByteStreamControllerShouldCallPull
const JSC::ConstructAbility s_readableByteStreamInternalsReadableByteStreamControllerShouldCallPullCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2822,7 +2822,7 @@ const JSC::ConstructorKind s_readableByteStreamInternalsReadableByteStreamContro
const JSC::ImplementationVisibility s_readableByteStreamInternalsReadableByteStreamControllerRespondCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableByteStreamInternalsReadableByteStreamControllerRespondCodeLength = 251;
static const JSC::Intrinsic s_readableByteStreamInternalsReadableByteStreamControllerRespondCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableByteStreamInternalsReadableByteStreamControllerRespondCode = "(function (I,u){\"use strict\";if(u=@toNumber(u),@isNaN(u)||u===@Infinity||u<0)@throwRangeError(\"bytesWritten has an incorrect value\");@assert(@getByIdDirectPrivate(I,\"pendingPullIntos\").isNotEmpty()),@readableByteStreamControllerRespondInternal(I,u)})\n";
+const char* const s_readableByteStreamInternalsReadableByteStreamControllerRespondCode = "(function (u,I){\"use strict\";if(I=@toNumber(I),@isNaN(I)||I===@Infinity||I<0)@throwRangeError(\"bytesWritten has an incorrect value\");@assert(@getByIdDirectPrivate(u,\"pendingPullIntos\").isNotEmpty()),@readableByteStreamControllerRespondInternal(u,I)})\n";
// readableByteStreamControllerRespondInternal
const JSC::ConstructAbility s_readableByteStreamInternalsReadableByteStreamControllerRespondInternalCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2862,7 +2862,7 @@ const JSC::ConstructorKind s_readableByteStreamInternalsReadableByteStreamContro
const JSC::ImplementationVisibility s_readableByteStreamInternalsReadableByteStreamControllerFillDescriptorFromQueueCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableByteStreamInternalsReadableByteStreamControllerFillDescriptorFromQueueCodeLength = 970;
static const JSC::Intrinsic s_readableByteStreamInternalsReadableByteStreamControllerFillDescriptorFromQueueCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableByteStreamInternalsReadableByteStreamControllerFillDescriptorFromQueueCode = "(function (_,z){\"use strict\";const q=z.bytesFilled-z.bytesFilled%z.elementSize,j=@getByIdDirectPrivate(_,\"queue\").size<z.byteLength-z.bytesFilled\?@getByIdDirectPrivate(_,\"queue\").size:z.byteLength-z.bytesFilled,v=z.bytesFilled+j,w=v-v%z.elementSize;let E=j,G=!1;if(w>q)E=w-z.bytesFilled,G=!0;while(E>0){let H=@getByIdDirectPrivate(_,\"queue\").content.peek();const k=E<H.byteLength\?E:H.byteLength,J=z.byteOffset+z.bytesFilled;if(new @Uint8Array(z.buffer).set(new @Uint8Array(H.buffer,H.byteOffset,k),J),H.byteLength===k)@getByIdDirectPrivate(_,\"queue\").content.shift();else H.byteOffset+=k,H.byteLength-=k;@getByIdDirectPrivate(_,\"queue\").size-=k,@assert(@getByIdDirectPrivate(_,\"pendingPullIntos\").isEmpty()||@getByIdDirectPrivate(_,\"pendingPullIntos\").peek()===z),@readableByteStreamControllerInvalidateBYOBRequest(_),z.bytesFilled+=k,E-=k}if(!G)@assert(@getByIdDirectPrivate(_,\"queue\").size===0),@assert(z.bytesFilled>0),@assert(z.bytesFilled<z.elementSize);return G})\n";
+const char* const s_readableByteStreamInternalsReadableByteStreamControllerFillDescriptorFromQueueCode = "(function (j,v){\"use strict\";const w=v.bytesFilled-v.bytesFilled%v.elementSize,z=@getByIdDirectPrivate(j,\"queue\").size<v.byteLength-v.bytesFilled\?@getByIdDirectPrivate(j,\"queue\").size:v.byteLength-v.bytesFilled,_=v.bytesFilled+z,G=_-_%v.elementSize;let q=z,H=!1;if(G>w)q=G-v.bytesFilled,H=!0;while(q>0){let J=@getByIdDirectPrivate(j,\"queue\").content.peek();const k=q<J.byteLength\?q:J.byteLength,E=v.byteOffset+v.bytesFilled;if(new @Uint8Array(v.buffer).set(new @Uint8Array(J.buffer,J.byteOffset,k),E),J.byteLength===k)@getByIdDirectPrivate(j,\"queue\").content.shift();else J.byteOffset+=k,J.byteLength-=k;@getByIdDirectPrivate(j,\"queue\").size-=k,@assert(@getByIdDirectPrivate(j,\"pendingPullIntos\").isEmpty()||@getByIdDirectPrivate(j,\"pendingPullIntos\").peek()===v),@readableByteStreamControllerInvalidateBYOBRequest(j),v.bytesFilled+=k,q-=k}if(!H)@assert(@getByIdDirectPrivate(j,\"queue\").size===0),@assert(v.bytesFilled>0),@assert(v.bytesFilled<v.elementSize);return H})\n";
// readableByteStreamControllerShiftPendingDescriptor
const JSC::ConstructAbility s_readableByteStreamInternalsReadableByteStreamControllerShiftPendingDescriptorCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2918,7 +2918,7 @@ const JSC::ConstructorKind s_readableByteStreamInternalsReadableByteStreamContro
const JSC::ImplementationVisibility s_readableByteStreamInternalsReadableByteStreamControllerPullIntoCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_readableByteStreamInternalsReadableByteStreamControllerPullIntoCodeLength = 1255;
static const JSC::Intrinsic s_readableByteStreamInternalsReadableByteStreamControllerPullIntoCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_readableByteStreamInternalsReadableByteStreamControllerPullIntoCode = "(function (_,b){\"use strict\";const E=@getByIdDirectPrivate(_,\"controlledReadableStream\");let d=1;if(b.BYTES_PER_ELEMENT!==@undefined)d=b.BYTES_PER_ELEMENT;const L=b.constructor,k={buffer:b.buffer,byteOffset:b.byteOffset,byteLength:b.byteLength,bytesFilled:0,elementSize:d,ctor:L,readerType:\"byob\"};var N=@getByIdDirectPrivate(_,\"pendingPullIntos\");if(N\?.isNotEmpty())return k.buffer=@transferBufferToCurrentRealm(k.buffer),N.push(k),@readableStreamAddReadIntoRequest(E);if(@getByIdDirectPrivate(E,\"state\")===@streamClosed){const R=new L(k.buffer,k.byteOffset,0);return @createFulfilledPromise({value:R,done:!0})}if(@getByIdDirectPrivate(_,\"queue\").size>0){if(@readableByteStreamControllerFillDescriptorFromQueue(_,k)){const R=@readableByteStreamControllerConvertDescriptor(k);return @readableByteStreamControllerHandleQueueDrain(_),@createFulfilledPromise({value:R,done:!1})}if(@getByIdDirectPrivate(_,\"closeRequested\")){const R=@makeTypeError(\"Closing stream has been requested\");return @readableByteStreamControllerError(_,R),@Promise.@reject(R)}}k.buffer=@transferBufferToCurrentRealm(k.buffer),@getByIdDirectPrivate(_,\"pendingPullIntos\").push(k);const A=@readableStreamAddReadIntoRequest(E);return @readableByteStreamControllerCallPullIfNeeded(_),A})\n";
+const char* const s_readableByteStreamInternalsReadableByteStreamControllerPullIntoCode = "(function (_,E){\"use strict\";const N=@getByIdDirectPrivate(_,\"controlledReadableStream\");let b=1;if(E.BYTES_PER_ELEMENT!==@undefined)b=E.BYTES_PER_ELEMENT;const d=E.constructor,k={buffer:E.buffer,byteOffset:E.byteOffset,byteLength:E.byteLength,bytesFilled:0,elementSize:b,ctor:d,readerType:\"byob\"};var A=@getByIdDirectPrivate(_,\"pendingPullIntos\");if(A\?.isNotEmpty())return k.buffer=@transferBufferToCurrentRealm(k.buffer),A.push(k),@readableStreamAddReadIntoRequest(N);if(@getByIdDirectPrivate(N,\"state\")===@streamClosed){const R=new d(k.buffer,k.byteOffset,0);return @createFulfilledPromise({value:R,done:!0})}if(@getByIdDirectPrivate(_,\"queue\").size>0){if(@readableByteStreamControllerFillDescriptorFromQueue(_,k)){const R=@readableByteStreamControllerConvertDescriptor(k);return @readableByteStreamControllerHandleQueueDrain(_),@createFulfilledPromise({value:R,done:!1})}if(@getByIdDirectPrivate(_,\"closeRequested\")){const R=@makeTypeError(\"Closing stream has been requested\");return @readableByteStreamControllerError(_,R),@Promise.@reject(R)}}k.buffer=@transferBufferToCurrentRealm(k.buffer),@getByIdDirectPrivate(_,\"pendingPullIntos\").push(k);const L=@readableStreamAddReadIntoRequest(N);return @readableByteStreamControllerCallPullIfNeeded(_),L})\n";
// readableStreamAddReadIntoRequest
const JSC::ConstructAbility s_readableByteStreamInternalsReadableStreamAddReadIntoRequestCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
@@ -2970,7 +2970,7 @@ const JSC::ConstructorKind s_eventSourceGetEventSourceCodeConstructorKind = JSC:
const JSC::ImplementationVisibility s_eventSourceGetEventSourceCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
const int s_eventSourceGetEventSourceCodeLength = 5477;
static const JSC::Intrinsic s_eventSourceGetEventSourceCodeIntrinsic = JSC::NoIntrinsic;
-const char* const s_eventSourceGetEventSourceCode = "(function (){\"use strict\";class w extends EventTarget{#$;#j;#w;#A;#B;#F=!1;#G=null;#J=\"\";#K=\"\";#L=\"\";#M=!0;#O=0;#Q=0;#U=0;#V=null;static#W(Z){Z.#H()}static#X(Z,A){const B=Z.data,F=B.#L\?`Last-Event-ID: ${B.#L}\\r\\n`:\"\",W=`GET ${A.pathname}${A.search} HTTP/1.1\\r\\nHost: bun\\r\\nContent-type: text/event-stream\\r\\nContent-length: 0\\r\\n${F}\\r\\n`,G=Z.write(W);if(G!==W.length)B.#K=W.substring(G)}static#Y(Z,A,B){for(;;){if(B>=A.length)return;let F=-1,W=A.indexOf(\"\\r\\n\",B);const G=W+2;if(W>0)if(Z.#O===0){const z=parseInt(A.substring(B,W),16);if(z===0){Z.#j=2,Z.#G\?.end();return}F=G+z}else F=A.length;else{if(Z.#J.length===0){Z.#J+=A.substring(B);return}F=A.length}let J=A.substring(G,F);B=F+2;let K=0,X=J.indexOf(\"\\n\\n\");if(X==-1){Z.#J+=A.substring(G);return}if(Z.#J.length)Z.#J+=J,J=Z.#J,Z.#J=\"\";let L=!0;while(L){const z=J.substring(K,X);let M,Y=\"\",O,H=0,Q=-1;for(;;){let U=z.indexOf(\"\\n\",H);if(U===-1){if(H>=z.length)break;U=z.length}const V=z.substring(H,U);if(V.startsWith(\"data:\"))if(Y.length)Y+=`\\n${V.substring(5).trim()}`;else Y=V.substring(5).trim();else if(V.startsWith(\"event:\"))M=V.substring(6).trim();else if(V.startsWith(\"id:\"))O=V.substring(3).trim();else if(V.startsWith(\"retry:\")){if(Q=parseInt(V.substring(6).trim(),10),@isNaN(Q))Q=-1}H=U+1}if(Z.#L=O||\"\",Q>=0)Z.#U=Q;if(Y||O||M)Z.dispatchEvent(new MessageEvent(M||\"message\",{data:Y||\"\",origin:Z.#$.origin,source:Z,lastEventId:O}));if(J.length===X+2){L=!1;break}const j=J.indexOf(\"\\n\\n\",X+1);if(j===-1)break;K=X,X=j}}}static#Z={open(Z){const A=Z.data;if(A.#G=Z,!A.#F)w.#X(Z,A.#$)},handshake(Z,A,B){const F=Z.data;if(A)w.#X(Z,F.#$);else F.#j=2,F.dispatchEvent(new ErrorEvent(\"error\",{error:B})),Z.end()},data(Z,A){const B=Z.data;switch(B.#j){case 0:{let F=A.toString();const W=F.indexOf(\"\\r\\n\\r\\n\");if(W===-1){B.#J+=F;return}if(B.#J.length)B.#J+=F,F=B.#J,B.#J=\"\";const G=F.substring(0,W),J=G.indexOf(\"\\r\\n\");if(J===-1){B.#j=2,B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Invalid HTTP request\")})),Z.end();return}const K=G.substring(0,J);if(K!==\"HTTP/1.1 200 OK\"){B.#j=2,B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(K)})),Z.end();return}let X=J+1,L=!1,z=-1;for(;;){let Y=G.indexOf(\"\\r\\n\",X);if(Y===-1){if(X>=G.length){if(!L)B.#j=2,B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's response has no MIME type and \"text/event-stream\" is required. Aborting the connection.`)})),Z.end();return}Y=G.length}const O=G.substring(X+1,Y),H=O.indexOf(\":\"),Q=O.substring(0,H),j=Q.localeCompare(\"content-type\",@undefined,{sensitivity:\"accent\"})===0;if(X=Y+1,j)if(O.endsWith(\" text/event-stream\"))L=!0;else{B.#j=2,B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's response has a MIME type that is not \"text/event-stream\". Aborting the connection.`)})),Z.end();return}else if(Q.localeCompare(\"content-length\",@undefined,{sensitivity:\"accent\"})===0){if(z=parseInt(O.substring(H+1).trim(),10),@isNaN(z)||z<=0){B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's Content-Length is invalid. Aborting the connection.`)})),Z.end();return}if(L)break}else if(Q.localeCompare(\"transfer-encoding\",@undefined,{sensitivity:\"accent\"})===0){if(O.substring(H+1).trim()!==\"chunked\"){B.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's Transfer-Encoding is invalid. Aborting the connection.`)})),Z.end();return}if(z=0,L)break}}B.#O=z,B.#j=1,B.dispatchEvent(new Event(\"open\"));const M=F.substring(W+4);if(w.#Y(B,M,0),B.#O>0){if(B.#Q+=M.length,B.#Q>=B.#O)B.#j=2,Z.end()}return}case 1:if(w.#Y(B,A.toString(),2),B.#O>0){if(B.#Q+=A.byteLength,B.#Q>=B.#O)B.#j=2,Z.end()}return;default:break}},drain(Z){const A=Z.data;if(A.#j===0){const B=A.#J;if(B.length){const F=Z.write(B);if(F!==B.length)Z.data.#K=B.substring(F);else Z.data.#K=\"\"}}},close:w.#z,end(Z){w.#z(Z).dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Connection closed by server\")}))},timeout(Z){w.#z(Z).dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Timeout\")}))},binaryType:\"buffer\"};static#z(Z){const A=Z.data;if(A.#G=null,A.#Q=0,A.#j=2,A.#M){if(A.#V)clearTimeout(A.#V);A.#V=setTimeout(w.#W,A.#U,A)}return A}constructor(Z,A=@undefined){super();const B=new URL(Z);this.#F=B.protocol===\"https:\",this.#$=B,this.#j=2,process.nextTick(w.#W,this)}ref(){this.#V\?.ref(),this.#G\?.ref()}unref(){this.#V\?.unref(),this.#G\?.unref()}#H(){if(this.#j!==2)return;const Z=this.#$,A=this.#F;this.#j=0,@Bun.connect({data:this,socket:w.#Z,hostname:Z.hostname,port:parseInt(Z.port||(A\?\"443\":\"80\"),10),tls:A\?{requestCert:!0,rejectUnauthorized:!1}:!1}).catch((B)=>{if(super.dispatchEvent(new ErrorEvent(\"error\",{error:B})),this.#M){if(this.#V)this.#V.unref\?.();this.#V=setTimeout(w.#W,1000,this)}})}get url(){return this.#$.href}get readyState(){return this.#j}close(){this.#M=!1,this.#j=2,this.#G\?.unref(),this.#G\?.end()}get onopen(){return this.#B}get onerror(){return this.#w}get onmessage(){return this.#A}set onopen(Z){if(this.#B)super.removeEventListener(\"close\",this.#B);super.addEventListener(\"open\",Z),this.#B=Z}set onerror(Z){if(this.#w)super.removeEventListener(\"error\",this.#w);super.addEventListener(\"error\",Z),this.#w=Z}set onmessage(Z){if(this.#A)super.removeEventListener(\"message\",this.#A);super.addEventListener(\"message\",Z),this.#A=Z}}return Object.defineProperty(w.prototype,\"CONNECTING\",{enumerable:!0,value:0}),Object.defineProperty(w.prototype,\"OPEN\",{enumerable:!0,value:1}),Object.defineProperty(w.prototype,\"CLOSED\",{enumerable:!0,value:2}),w[Symbol.for(\"CommonJS\")]=0,w})\n";
+const char* const s_eventSourceGetEventSourceCode = "(function (){\"use strict\";class j extends EventTarget{#$;#j;#w;#A;#B;#F=!1;#G=null;#J=\"\";#K=\"\";#L=\"\";#M=!0;#O=0;#Q=0;#U=0;#V=null;static#W(M){M.#H()}static#X(M,L){const w=M.data,O=w.#L\?`Last-Event-ID: ${w.#L}\\r\\n`:\"\",A=`GET ${L.pathname}${L.search} HTTP/1.1\\r\\nHost: bun\\r\\nContent-type: text/event-stream\\r\\nContent-length: 0\\r\\n${O}\\r\\n`,Q=M.write(A);if(Q!==A.length)w.#K=A.substring(Q)}static#Y(M,L,w){for(;;){if(w>=L.length)return;let O=-1,A=L.indexOf(\"\\r\\n\",w);const Q=A+2;if(A>0)if(M.#O===0){const Y=parseInt(L.substring(w,A),16);if(Y===0){M.#j=2,M.#G\?.end();return}O=Q+Y}else O=L.length;else{if(M.#J.length===0){M.#J+=L.substring(w);return}O=L.length}let U=L.substring(Q,O);w=O+2;let V=0,W=U.indexOf(\"\\n\\n\");if(W==-1){M.#J+=L.substring(Q);return}if(M.#J.length)M.#J+=U,U=M.#J,M.#J=\"\";let X=!0;while(X){const Y=U.substring(V,W);let Z,z=\"\",J,B=0,H=-1;for(;;){let G=Y.indexOf(\"\\n\",B);if(G===-1){if(B>=Y.length)break;G=Y.length}const K=Y.substring(B,G);if(K.startsWith(\"data:\"))if(z.length)z+=`\\n${K.substring(5).trim()}`;else z=K.substring(5).trim();else if(K.startsWith(\"event:\"))Z=K.substring(6).trim();else if(K.startsWith(\"id:\"))J=K.substring(3).trim();else if(K.startsWith(\"retry:\")){if(H=parseInt(K.substring(6).trim(),10),@isNaN(H))H=-1}B=G+1}if(M.#L=J||\"\",H>=0)M.#U=H;if(z||J||Z)M.dispatchEvent(new MessageEvent(Z||\"message\",{data:z||\"\",origin:M.#$.origin,source:M,lastEventId:J}));if(U.length===W+2){X=!1;break}const F=U.indexOf(\"\\n\\n\",W+1);if(F===-1)break;V=W,W=F}}}static#Z={open(M){const L=M.data;if(L.#G=M,!L.#F)j.#X(M,L.#$)},handshake(M,L,w){const O=M.data;if(L)j.#X(M,O.#$);else O.#j=2,O.dispatchEvent(new ErrorEvent(\"error\",{error:w})),M.end()},data(M,L){const w=M.data;switch(w.#j){case 0:{let O=L.toString();const A=O.indexOf(\"\\r\\n\\r\\n\");if(A===-1){w.#J+=O;return}if(w.#J.length)w.#J+=O,O=w.#J,w.#J=\"\";const Q=O.substring(0,A),U=Q.indexOf(\"\\r\\n\");if(U===-1){w.#j=2,w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Invalid HTTP request\")})),M.end();return}const V=Q.substring(0,U);if(V!==\"HTTP/1.1 200 OK\"){w.#j=2,w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(V)})),M.end();return}let W=U+1,X=!1,Y=-1;for(;;){let z=Q.indexOf(\"\\r\\n\",W);if(z===-1){if(W>=Q.length){if(!X)w.#j=2,w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's response has no MIME type and \"text/event-stream\" is required. Aborting the connection.`)})),M.end();return}z=Q.length}const J=Q.substring(W+1,z),B=J.indexOf(\":\"),H=J.substring(0,B),F=H.localeCompare(\"content-type\",@undefined,{sensitivity:\"accent\"})===0;if(W=z+1,F)if(J.endsWith(\" text/event-stream\"))X=!0;else{w.#j=2,w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's response has a MIME type that is not \"text/event-stream\". Aborting the connection.`)})),M.end();return}else if(H.localeCompare(\"content-length\",@undefined,{sensitivity:\"accent\"})===0){if(Y=parseInt(J.substring(B+1).trim(),10),@isNaN(Y)||Y<=0){w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's Content-Length is invalid. Aborting the connection.`)})),M.end();return}if(X)break}else if(H.localeCompare(\"transfer-encoding\",@undefined,{sensitivity:\"accent\"})===0){if(J.substring(B+1).trim()!==\"chunked\"){w.dispatchEvent(new ErrorEvent(\"error\",{error:new Error(`EventSource's Transfer-Encoding is invalid. Aborting the connection.`)})),M.end();return}if(Y=0,X)break}}w.#O=Y,w.#j=1,w.dispatchEvent(new Event(\"open\"));const Z=O.substring(A+4);if(j.#Y(w,Z,0),w.#O>0){if(w.#Q+=Z.length,w.#Q>=w.#O)w.#j=2,M.end()}return}case 1:if(j.#Y(w,L.toString(),2),w.#O>0){if(w.#Q+=L.byteLength,w.#Q>=w.#O)w.#j=2,M.end()}return;default:break}},drain(M){const L=M.data;if(L.#j===0){const w=L.#J;if(w.length){const O=M.write(w);if(O!==w.length)M.data.#K=w.substring(O);else M.data.#K=\"\"}}},close:j.#z,end(M){j.#z(M).dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Connection closed by server\")}))},timeout(M){j.#z(M).dispatchEvent(new ErrorEvent(\"error\",{error:new Error(\"Timeout\")}))},binaryType:\"buffer\"};static#z(M){const L=M.data;if(L.#G=null,L.#Q=0,L.#j=2,L.#M){if(L.#V)clearTimeout(L.#V);L.#V=setTimeout(j.#W,L.#U,L)}return L}constructor(M,L=@undefined){super();const w=new URL(M);this.#F=w.protocol===\"https:\",this.#$=w,this.#j=2,process.nextTick(j.#W,this)}ref(){this.#V\?.ref(),this.#G\?.ref()}unref(){this.#V\?.unref(),this.#G\?.unref()}#H(){if(this.#j!==2)return;const M=this.#$,L=this.#F;this.#j=0,@Bun.connect({data:this,socket:j.#Z,hostname:M.hostname,port:parseInt(M.port||(L\?\"443\":\"80\"),10),tls:L\?{requestCert:!0,rejectUnauthorized:!1}:!1}).catch((w)=>{if(super.dispatchEvent(new ErrorEvent(\"error\",{error:w})),this.#M){if(this.#V)this.#V.unref\?.();this.#V=setTimeout(j.#W,1000,this)}})}get url(){return this.#$.href}get readyState(){return this.#j}close(){this.#M=!1,this.#j=2,this.#G\?.unref(),this.#G\?.end()}get onopen(){return this.#B}get onerror(){return this.#w}get onmessage(){return this.#A}set onopen(M){if(this.#B)super.removeEventListener(\"close\",this.#B);super.addEventListener(\"open\",M),this.#B=M}set onerror(M){if(this.#w)super.removeEventListener(\"error\",this.#w);super.addEventListener(\"error\",M),this.#w=M}set onmessage(M){if(this.#A)super.removeEventListener(\"message\",this.#A);super.addEventListener(\"message\",M),this.#A=M}}return Object.defineProperty(j.prototype,\"CONNECTING\",{enumerable:!0,value:0}),Object.defineProperty(j.prototype,\"OPEN\",{enumerable:!0,value:1}),Object.defineProperty(j.prototype,\"CLOSED\",{enumerable:!0,value:2}),j[Symbol.for(\"CommonJS\")]=0,j})\n";
#define DEFINE_BUILTIN_GENERATOR(codeName, functionName, overriddenName, argumentCount) \
JSC::FunctionExecutable* codeName##Generator(JSC::VM& vm) \