mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 10:28:47 +00:00
mild clean up
This commit is contained in:
@@ -94,7 +94,7 @@ const char* const s_readableStreamDefaultReaderCancelCode =
|
||||
const JSC::ConstructAbility s_readableStreamDefaultReaderReadManyCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
|
||||
const JSC::ConstructorKind s_readableStreamDefaultReaderReadManyCodeConstructorKind = JSC::ConstructorKind::None;
|
||||
const JSC::ImplementationVisibility s_readableStreamDefaultReaderReadManyCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
|
||||
const int s_readableStreamDefaultReaderReadManyCodeLength = 4661;
|
||||
const int s_readableStreamDefaultReaderReadManyCodeLength = 4743;
|
||||
static const JSC::Intrinsic s_readableStreamDefaultReaderReadManyCodeIntrinsic = JSC::NoIntrinsic;
|
||||
const char* const s_readableStreamDefaultReaderReadManyCode =
|
||||
"(function ()\n" \
|
||||
@@ -126,11 +126,14 @@ const char* const s_readableStreamDefaultReaderReadManyCode =
|
||||
" return controller.@pull(\n" \
|
||||
" controller\n" \
|
||||
" ).@then(\n" \
|
||||
" ({done, value}) => (\n" \
|
||||
" done ? \n" \
|
||||
" { done: true, value: [], size: 0 } : \n" \
|
||||
" { value: [value], size: 1, done: false }\n" \
|
||||
" ));\n" \
|
||||
" function({done, value}) {\n" \
|
||||
" return (\n" \
|
||||
" done ? \n" \
|
||||
" { done: true, value: [], size: 0 } : \n" \
|
||||
" { value: [value], size: 1, done: false }\n" \
|
||||
" );\n" \
|
||||
" }\n" \
|
||||
" );\n" \
|
||||
" }\n" \
|
||||
"\n" \
|
||||
" const content = queue.content;\n" \
|
||||
|
||||
@@ -986,7 +986,7 @@ const char* const s_readableStreamInternalsIsReadableStreamDefaultControllerCode
|
||||
const JSC::ConstructAbility s_readableStreamInternalsReadDirectStreamCodeConstructAbility = JSC::ConstructAbility::CannotConstruct;
|
||||
const JSC::ConstructorKind s_readableStreamInternalsReadDirectStreamCodeConstructorKind = JSC::ConstructorKind::None;
|
||||
const JSC::ImplementationVisibility s_readableStreamInternalsReadDirectStreamCodeImplementationVisibility = JSC::ImplementationVisibility::Public;
|
||||
const int s_readableStreamInternalsReadDirectStreamCodeLength = 1582;
|
||||
const int s_readableStreamInternalsReadDirectStreamCodeLength = 1557;
|
||||
static const JSC::Intrinsic s_readableStreamInternalsReadDirectStreamCodeIntrinsic = JSC::NoIntrinsic;
|
||||
const char* const s_readableStreamInternalsReadDirectStreamCode =
|
||||
"(function (stream, sink, underlyingSource) {\n" \
|
||||
@@ -995,10 +995,6 @@ const char* const s_readableStreamInternalsReadDirectStreamCode =
|
||||
" @putByIdDirectPrivate(stream, \"underlyingSource\", @undefined);\n" \
|
||||
" @putByIdDirectPrivate(stream, \"start\", @undefined);\n" \
|
||||
"\n" \
|
||||
"\n" \
|
||||
" var capturedStream = stream;\n" \
|
||||
" var reader;\n" \
|
||||
"\n" \
|
||||
" function close(stream, reason) {\n" \
|
||||
" if (reason && underlyingSource?.cancel) {\n" \
|
||||
" try {\n" \
|
||||
@@ -1019,7 +1015,7 @@ const char* const s_readableStreamInternalsReadDirectStreamCode =
|
||||
" } else {\n" \
|
||||
" @putByIdDirectPrivate(stream, \"state\", @streamClosed);\n" \
|
||||
" }\n" \
|
||||
" \n" \
|
||||
" stream = @undefined;\n" \
|
||||
" }\n" \
|
||||
" }\n" \
|
||||
"\n" \
|
||||
@@ -1056,6 +1052,7 @@ const char* const s_readableStreamInternalsReadDirectStreamCode =
|
||||
" return maybePromise.@then(() => {});\n" \
|
||||
" }\n" \
|
||||
"\n" \
|
||||
"\n" \
|
||||
"})\n" \
|
||||
;
|
||||
|
||||
|
||||
@@ -80,11 +80,14 @@ function readMany()
|
||||
return controller.@pull(
|
||||
controller
|
||||
).@then(
|
||||
({done, value}) => (
|
||||
done ?
|
||||
{ done: true, value: [], size: 0 } :
|
||||
{ value: [value], size: 1, done: false }
|
||||
));
|
||||
function({done, value}) {
|
||||
return (
|
||||
done ?
|
||||
{ done: true, value: [], size: 0 } :
|
||||
{ value: [value], size: 1, done: false }
|
||||
);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
const content = queue.content;
|
||||
|
||||
@@ -795,10 +795,6 @@ function readDirectStream(stream, sink, underlyingSource) {
|
||||
@putByIdDirectPrivate(stream, "underlyingSource", @undefined);
|
||||
@putByIdDirectPrivate(stream, "start", @undefined);
|
||||
|
||||
|
||||
var capturedStream = stream;
|
||||
var reader;
|
||||
|
||||
function close(stream, reason) {
|
||||
if (reason && underlyingSource?.cancel) {
|
||||
try {
|
||||
@@ -819,7 +815,7 @@ function readDirectStream(stream, sink, underlyingSource) {
|
||||
} else {
|
||||
@putByIdDirectPrivate(stream, "state", @streamClosed);
|
||||
}
|
||||
|
||||
stream = @undefined;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -856,6 +852,7 @@ function readDirectStream(stream, sink, underlyingSource) {
|
||||
return maybePromise.@then(() => {});
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@linkTimeConstant;
|
||||
|
||||
Reference in New Issue
Block a user