diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2020-11-03 16:19:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-03 16:19:29 +0100 |
commit | 8e914be7420715620cad74fbb020c5e87ac875a2 (patch) | |
tree | 2fefc0111f85533de2bd24e54f70c6c1241e3d3b /op_crates/fetch/11_streams.js | |
parent | e736d0f60f6cdf38e2d317ee08a7125de9e57d69 (diff) |
build: migrate to dlint (#8176)
This commit migrates repository from using "eslint"
to "dlint" for linting JavaScript code.
Diffstat (limited to 'op_crates/fetch/11_streams.js')
-rw-r--r-- | op_crates/fetch/11_streams.js | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/op_crates/fetch/11_streams.js b/op_crates/fetch/11_streams.js index b182a96ed..1c1889e09 100644 --- a/op_crates/fetch/11_streams.js +++ b/op_crates/fetch/11_streams.js @@ -7,10 +7,23 @@ // comments which point to steps of the specification that are not implemented. ((window) => { - /* eslint-disable @typescript-eslint/no-explicit-any,require-await */ - const customInspect = Symbol.for("Deno.customInspect"); + function cloneArrayBuffer( + srcBuffer, + srcByteOffset, + srcLength, + _cloneConstructor, + ) { + // this function fudges the return type but SharedArrayBuffer is disabled for a while anyway + return srcBuffer.slice( + srcByteOffset, + srcByteOffset + srcLength, + ); + } + + const objectCloneMemo = new WeakMap(); + /** Clone a value in a similar way to structured cloning. It is similar to a * StructureDeserialize(StructuredSerialize(...)). */ function cloneValue(value) { @@ -88,6 +101,7 @@ } case "symbol": case "function": + // fallthrough default: throw new DOMException("Uncloneable value in stream", "DataCloneError"); } @@ -2151,10 +2165,10 @@ let canceled2 = false; let reason1 = undefined; let reason2 = undefined; - /* eslint-disable prefer-const */ + // deno-lint-ignore prefer-const let branch1; + // deno-lint-ignore prefer-const let branch2; - /* eslint-enable prefer-const */ const cancelPromise = getDeferred(); const pullAlgorithm = () => { if (reading) { @@ -3365,7 +3379,6 @@ } stream[sym.backpressure] = backpressure; } - /* eslint-enable */ class CountQueuingStrategy { constructor({ highWaterMark }) { |