From ff117ae77f81a248ba844595e2dd8f28b4137d98 Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 03:33:03 -0800 Subject: [PATCH 1/6] chore(quest): claim quest/m2/ts-model/iter-traits.md Quest-Claim: a87a285c11280bd5 From 866d49be3dbc1c7beab5e1c7a3574651c5d9e23c Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 04:13:25 -0800 Subject: [PATCH 2/6] feat(ts): translate a crate's own double-ended, exact-size, and fused iterators Co-Authored-By: Claude Opus 5.5 --- ts/README.md | 6 +- ts/fixtures/crates/Cargo.toml | 2 - ts/fixtures/crates/dep/Cargo.toml | 4 - ts/fixtures/crates/dep/src/lib.rs | 1 - .../crates/expected/crates_dep.Countdown.ts | 8 + ts/fixtures/crates/expected/harness.ts | 21 +- ts/fixtures/crates/refused.txt | 4 +- ts/fixtures/crates/rev.txt | 1 - ts/fixtures/crates/src/harness.rs | 7 + ts/fixtures/lang/caller.ts | 13 +- ts/fixtures/lang/expected/core/option.ts | 7 + ts/fixtures/lang/expected/ends.Counted.ts | 28 + ts/fixtures/lang/expected/ends.Flicker.ts | 24 + ts/fixtures/lang/expected/ends.Lapse.ts | 15 + ts/fixtures/lang/expected/ends.Run.ts | 59 + ts/fixtures/lang/expected/ends.ts | 270 ++++ ts/fixtures/lang/expected/harness.ts | 3 + ts/fixtures/lang/src/ends.rs | 260 ++++ ts/fixtures/lang/src/harness.rs | 9 +- ts/fixtures/lang/src/lib.rs | 3 +- ts/fixtures/reject/census.md | 1155 ++++++++--------- ts/fixtures/reject/expected.txt | 406 +++--- ts/fixtures/reject/src/lib.rs | 47 +- ts/fixtures/reject/ts.toml | 2 - ts/fixtures/stock/caller.ts | 12 +- ts/fixtures/stock/expected/core/option.ts | 42 + ts/fixtures/stock/expected/harness.ts | 6 +- .../hashlink/linked_hash_map.Drain.ts | 63 + .../hashlink/linked_hash_map.IntoIter.ts | 56 + .../expected/hashlink/linked_hash_map.Iter.ts | 38 + .../hashlink/linked_hash_map.IterMut.ts | 40 + .../expected/hashlink/linked_hash_map.Keys.ts | 31 + .../hashlink/linked_hash_map.LinkedHashMap.ts | 89 +- .../hashlink/linked_hash_map.Values.ts | 31 + .../hashlink/linked_hash_map.ValuesMut.ts | 31 + ts/fixtures/stock/expected/lib.ts | 10 + ts/fixtures/stock/expected/maps.ts | 357 ++++- ts/fixtures/stock/src/harness.rs | 1 + ts/fixtures/stock/src/maps.rs | 71 +- ts/runtime/rt/iter.ts | 80 +- ts/src/lower/iter.rs | 139 +- ts/tests/fixtures.rs | 9 +- 42 files changed, 2542 insertions(+), 919 deletions(-) delete mode 100644 ts/fixtures/crates/rev.txt create mode 100644 ts/fixtures/lang/expected/ends.Counted.ts create mode 100644 ts/fixtures/lang/expected/ends.Flicker.ts create mode 100644 ts/fixtures/lang/expected/ends.Lapse.ts create mode 100644 ts/fixtures/lang/expected/ends.Run.ts create mode 100644 ts/fixtures/lang/expected/ends.ts create mode 100644 ts/fixtures/lang/src/ends.rs create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.Drain.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.IntoIter.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.Iter.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.IterMut.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.Keys.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.Values.ts create mode 100644 ts/fixtures/stock/expected/hashlink/linked_hash_map.ValuesMut.ts diff --git a/ts/README.md b/ts/README.md index cadf317f4..e0fd18c83 100644 --- a/ts/README.md +++ b/ts/README.md @@ -274,7 +274,8 @@ compare the best and then the next, and a B-tree's iterators read their ends. `e An iterator over a slice, array, or `Vec`, or a small range, that only its `next` and moves read steps in place, as two variables: the array and an index into it, or the range's bounds, with no `rt.Iter` made. The crate's own `impl Iterator` returns `rt.DONE` from its `next` too, and joins -std's adaptors through `rt.iterFrom`. A caller calls `next()` for one item, or iterates +std's adaptors through `rt.iterFrom`, which calls its own `size_hint`, `next_back`, and `len` where std's adaptors +call them, and `fuse` reads on past the end of one that is a `FusedIterator`, as std's does. A caller calls `next()` for one item, or iterates an `rt.Iter` with `for ... of`. Each `rt.Iter`'s `sizeHint` is std's `size_hint`, its upper bound `undefined` for `None`, and a `collect` or `extend` into a `Vec`, `VecDeque`, `BinaryHeap`, B-tree, or hash collection reserves by it where std's does, panicking with @@ -853,7 +854,8 @@ another type it borrows as through the crate's own `Borrow`, a `&mut` to a value copies that std makes, other than a map's, or hands a closure, as `iter_mut` and `and_modify` do, one into a `Result`'s payload passed on or kept, `Hasher::write` of bytes, the adaptors without a mapping in `src/lower/iter.rs` (such as `partition`), an -own `impl Iterator` with `next_back`, `len`, or another provided method of its own, +own `impl Iterator` or `DoubleEndedIterator` that overrides a provided method other than +`size_hint` and `len`, such as `fold` or `nth_back`, a pointer's address (`{:p}`), `write!` with a placeholder into the crate's own `fmt::Write`, a `str` pattern other than a `char`, a `&str`, a predicate, or chars, a mutable `str` slice, a copy of a closure that changes diff --git a/ts/fixtures/crates/Cargo.toml b/ts/fixtures/crates/Cargo.toml index c7a5cf87a..f59ef602d 100644 --- a/ts/fixtures/crates/Cargo.toml +++ b/ts/fixtures/crates/Cargo.toml @@ -13,8 +13,6 @@ crate-type = ["lib", "cdylib"] [features] # A module of the dependency's name, whose files would be the dependency's. shared = [] -# The dependency's iterator runs from either end, which translation refuses. -rev = ["crates-dep/rev"] # A type of the crate's own whose path a suffix spells as it does std's. alike = [] diff --git a/ts/fixtures/crates/dep/Cargo.toml b/ts/fixtures/crates/dep/Cargo.toml index fcab35cbf..f715c28b6 100644 --- a/ts/fixtures/crates/dep/Cargo.toml +++ b/ts/fixtures/crates/dep/Cargo.toml @@ -6,9 +6,5 @@ edition.workspace = true license.workspace = true publish = false -[features] -# `Countdown` runs from either end. -rev = [] - [lints] workspace = true diff --git a/ts/fixtures/crates/dep/src/lib.rs b/ts/fixtures/crates/dep/src/lib.rs index 2b5a0be32..35671f4d9 100644 --- a/ts/fixtures/crates/dep/src/lib.rs +++ b/ts/fixtures/crates/dep/src/lib.rs @@ -77,7 +77,6 @@ impl Iterator for Countdown { } } -#[cfg(feature = "rev")] impl DoubleEndedIterator for Countdown { fn next_back(&mut self) -> Option { if self.next == self.last { diff --git a/ts/fixtures/crates/expected/crates_dep.Countdown.ts b/ts/fixtures/crates/expected/crates_dep.Countdown.ts index 21bd76bbb..4ed98b58c 100644 --- a/ts/fixtures/crates/expected/crates_dep.Countdown.ts +++ b/ts/fixtures/crates/expected/crates_dep.Countdown.ts @@ -20,6 +20,14 @@ export function next$iter_Iterator(self: Countdown): rt.u8 | rt.Done { return rt.DONE; } +export function nextBack$iter_DoubleEndedIterator(self: Countdown): rt.u8 | undefined { + if (!(self.next === self.last)) { + self.last = rt.u8Add(self.last, 1); + return self.last; + } + return undefined; +} + export { new_ as new }; //# sourceMappingURL=crates_dep.Countdown.ts.map diff --git a/ts/fixtures/crates/expected/harness.ts b/ts/fixtures/crates/expected/harness.ts index 476480ace..3b8620691 100644 --- a/ts/fixtures/crates/expected/harness.ts +++ b/ts/fixtures/crates/expected/harness.ts @@ -73,14 +73,27 @@ export function run(input: rt.ByteSlice): rt.ByteVec { } rt.byteVecPush(out, _143); } + const _151: rt.Iter = rt.iterRev(rt.iterFrom(Countdown.new(rt.min(input.length, 5) & 0xff), (it: Countdown.Countdown) => Countdown.next$iter_Iterator(it), undefined, undefined, (it: Countdown.Countdown) => rt.iterFromOption(Countdown.nextBack$iter_DoubleEndedIterator(it)))); + rt.iterExtendBytes(out, _151, "next"); + const both: Countdown.Countdown = Countdown.new(rt.min(input.length, 6) & 0xff); + while (true) { + const _160: rt.u8 | undefined = Countdown.nextBack$iter_DoubleEndedIterator(both); + if (_160 !== undefined) { + rt.byteVecPush(out, _160); + const _168: rt.u8 | undefined = rt.iterToOption(Countdown.next$iter_Iterator(both)); + rt.iterExtendBytes(out, rt.iterOption(_168), undefined, true); + } else { + break; + } + } const kept: rt.i16[] = [(input.length << 16) >> 16, 7]; const filled: rt.i16[] = copy$array_i16(kept); Slots.fill(Slots.withBase(kept[0]), filled); rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(kept[0] & 0xff, kept[1] & 0xff, filled[0] & 0xff, filled[1] & 0xff)), undefined, true); - const _181: rt.u8 = first(input.data, input.start, input.length); - rt.byteVecPush(out, _181); - const _184: rt.u8 = last.last(input); - rt.byteVecPush(out, _184); + const _202: rt.u8 = first(input.data, input.start, input.length); + rt.byteVecPush(out, _202); + const _205: rt.u8 = last.last(input); + rt.byteVecPush(out, _205); log[Symbol.dispose](); return out; } diff --git a/ts/fixtures/crates/refused.txt b/ts/fixtures/crates/refused.txt index bfc265279..f54ab04ef 100644 --- a/ts/fixtures/crates/refused.txt +++ b/ts/fixtures/crates/refused.txt @@ -1,2 +1,2 @@ -unsupported call to `core::slice::::as_ptr` at fixtures/crates/dep/src/lib.rs:129:18 -unsupported call to `std::ptr::const_ptr::::add` at fixtures/crates/dep/src/lib.rs:129:27 +unsupported call to `core::slice::::as_ptr` at fixtures/crates/dep/src/lib.rs:128:18 +unsupported call to `std::ptr::const_ptr::::add` at fixtures/crates/dep/src/lib.rs:128:27 diff --git a/ts/fixtures/crates/rev.txt b/ts/fixtures/crates/rev.txt deleted file mode 100644 index 9f1cf5c2b..000000000 --- a/ts/fixtures/crates/rev.txt +++ /dev/null @@ -1 +0,0 @@ -an iterator of the crate implementing `DoubleEndedIterator`, which is not supported yet at fixtures/crates/dep/src/lib.rs:81:1 diff --git a/ts/fixtures/crates/src/harness.rs b/ts/fixtures/crates/src/harness.rs index 5208d7360..231e266d6 100644 --- a/ts/fixtures/crates/src/harness.rs +++ b/ts/fixtures/crates/src/harness.rs @@ -70,6 +70,13 @@ pub fn run(input: &[u8]) -> Vec { for n in Countdown::new(input.len().min(4) as u8) { out.push(n); } + // The dependency's iterator, from the back and then from either end until they meet. + out.extend(Countdown::new(input.len().min(5) as u8).rev()); + let mut both = Countdown::new(input.len().min(6) as u8); + while let Some(n) = both.next_back() { + out.push(n); + out.extend(both.next()); + } // Only the binding writes into a `[i16; 2]`, so the copy must not share it. let kept: [i16; 2] = [input.len() as i16, 7]; let mut filled = kept; diff --git a/ts/fixtures/lang/caller.ts b/ts/fixtures/lang/caller.ts index 5e12e45c1..9e1e435f0 100644 --- a/ts/fixtures/lang/caller.ts +++ b/ts/fixtures/lang/caller.ts @@ -864,4 +864,15 @@ const capacityCases = [ ...Array.from({ length: 8 * 6 }, (_, i) => Uint8Array.of(...op("capacity::collects"), i % 8, [0, 1, 2, 5, 9, 23][Math.floor(i / 8)], 1, 2, 3, 4, 5, 6, 7, 8, 9, 10)), ]; -export const cases: Uint8Array[] = [...loops, ...durations, ...ints(), ...utf8, ...floats, ...formats, ...parsed, ...singlesCases, ...singlesFormats, ...singlesParsed, ...dyns, ...cells, ...shared, ...locks, ...guards, ...maps, ...mappedLocks, ...relocks, ...tries, ...mutexMaps, ...printed, ...downgrades, ...leaks, ...rwlocks, ...onces, ...bounds, ...unsafeCells, ...edits, ...subslices, ...consumers, ...closures, ...elements, ...ranges, ...reducers, ...sliceEdits, ...drains, ...iters, ...hinted, ...peekedOthers, ...hints, ...reserves, ...setOps, ...zeros, ...writes, ...floatsMulAdds, ...singlesMulAdds, ...unlikeEqs, ...ownNes, ...rangeFroms, ...compares, ...unlikeCompares, ...rangeMethods, ...wraps(), ...refOrders, ...saturates(), ...methods(), ...separated, ...asciiCases, ...gets, ...capacityCases]; +/** + * `ends::ends`: each kind of iterator through every consumer and either end's bits, of + * runs empty, short, and long, whose hints are exact, loose, and lying, after none and a + * few steps through each of its methods. + */ +const endsCases = [0x00, 0x03, 0x0f, 0x15, 0x27, 0x36, 0x2f].flatMap((shape) => + [[], [0x01, 0x00], [0x0a, 0x03], [0x05, 0x06, 0x04, 0x0f]].flatMap((steps) => + Array.from({ length: 4 * 256 }, (_, i) => Uint8Array.of(...op("ends::ends"), i % 4, shape, i >> 2, ...steps)), + ), +); + +export const cases: Uint8Array[] = [...loops, ...durations, ...ints(), ...utf8, ...floats, ...formats, ...parsed, ...singlesCases, ...singlesFormats, ...singlesParsed, ...dyns, ...cells, ...shared, ...locks, ...guards, ...maps, ...mappedLocks, ...relocks, ...tries, ...mutexMaps, ...printed, ...downgrades, ...leaks, ...rwlocks, ...onces, ...bounds, ...unsafeCells, ...edits, ...subslices, ...consumers, ...closures, ...elements, ...ranges, ...reducers, ...sliceEdits, ...drains, ...iters, ...hinted, ...peekedOthers, ...hints, ...reserves, ...setOps, ...zeros, ...writes, ...floatsMulAdds, ...singlesMulAdds, ...unlikeEqs, ...ownNes, ...rangeFroms, ...compares, ...unlikeCompares, ...rangeMethods, ...wraps(), ...refOrders, ...saturates(), ...methods(), ...separated, ...asciiCases, ...gets, ...capacityCases, ...endsCases]; diff --git a/ts/fixtures/lang/expected/core/option.ts b/ts/fixtures/lang/expected/core/option.ts index d560b69e0..9cb686cd7 100644 --- a/ts/fixtures/lang/expected/core/option.ts +++ b/ts/fixtures/lang/expected/core/option.ts @@ -819,6 +819,13 @@ export function map$0cs071d(self: rt.u8 | undefined, f: (a0: rt.u8) => rt.u8): r return f(self); } +export function map$0vbopjd(self: rt.u8 | undefined, f: (a0: rt.u8) => rt.usize): rt.usize | undefined { + if (self === undefined) { + return undefined; + } + return f(self); +} + export function map$0at3a41(self: undefined | rt.None, f: (a0: undefined) => rt.u8 | undefined): rt.u8 | undefined | rt.None { if (self === rt.None) { return rt.None; diff --git a/ts/fixtures/lang/expected/ends.Counted.ts b/ts/fixtures/lang/expected/ends.Counted.ts new file mode 100644 index 000000000..fdfea08ce --- /dev/null +++ b/ts/fixtures/lang/expected/ends.Counted.ts @@ -0,0 +1,28 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "./rt.ts"; +import * as ends_Run from "./ends.Run.ts"; + +/** A `Run` whose `len` is its own, which reads the run's, as hashlink's `Values` does. */ +export interface Counted { + _0: ends_Run.Run; +} + +export function next$iter_Iterator(self: Counted): rt.u8 | rt.Done { + return ends_Run.next$iter_Iterator(self._0); +} + +export function sizeHint$iter_Iterator(self: Counted): [rt.usize, rt.usize | undefined] { + return ends_Run.sizeHint$iter_Iterator(self._0); +} + +export function nextBack$iter_DoubleEndedIterator(self: Counted): rt.u8 | undefined { + return ends_Run.nextBack$iter_DoubleEndedIterator(self._0); +} + +export function len$iter_ExactSizeIterator(self: Counted): rt.usize { + ends_Run.logged(self._0, 108); + return rt.iterFrom(self._0, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len(); +} + +//# sourceMappingURL=ends.Counted.ts.map diff --git a/ts/fixtures/lang/expected/ends.Flicker.ts b/ts/fixtures/lang/expected/ends.Flicker.ts new file mode 100644 index 000000000..55c15133c --- /dev/null +++ b/ts/fixtures/lang/expected/ends.Flicker.ts @@ -0,0 +1,24 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "./rt.ts"; +import { thenSome$0d5am30 } from "./core/bool.ts"; + +/** + * Yields every other call to `next`, from either end, ending between: a `FusedIterator` + * that isn't, which std's `fuse` reads on from as it would one that is. + */ +export interface Flicker { + _0: rt.u8; +} + +export function next$iter_Iterator(self: Flicker): rt.u8 | rt.Done { + self._0 = rt.u8WrappingAdd(self._0, 1); + return rt.iterFromOption(thenSome$0d5am30(rt.u8Rem(self._0, 2) === 0, self._0)); +} + +export function nextBack$iter_DoubleEndedIterator(self: Flicker): rt.u8 | undefined { + self._0 = rt.u8WrappingAdd(self._0, 3); + return thenSome$0d5am30(rt.u8Rem(self._0, 2) === 0, self._0); +} + +//# sourceMappingURL=ends.Flicker.ts.map diff --git a/ts/fixtures/lang/expected/ends.Lapse.ts b/ts/fixtures/lang/expected/ends.Lapse.ts new file mode 100644 index 000000000..c68bc0568 --- /dev/null +++ b/ts/fixtures/lang/expected/ends.Lapse.ts @@ -0,0 +1,15 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "./rt.ts"; +import * as Flicker from "./ends.Flicker.ts"; + +/** As `Flicker`, without its `FusedIterator`, so std's `fuse` ends it at its first `None`. */ +export interface Lapse { + _0: Flicker.Flicker; +} + +export function next$iter_Iterator(self: Lapse): rt.u8 | rt.Done { + return Flicker.next$iter_Iterator(self._0); +} + +//# sourceMappingURL=ends.Lapse.ts.map diff --git a/ts/fixtures/lang/expected/ends.Run.ts b/ts/fixtures/lang/expected/ends.Run.ts new file mode 100644 index 000000000..cf2990809 --- /dev/null +++ b/ts/fixtures/lang/expected/ends.Run.ts @@ -0,0 +1,59 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "./rt.ts"; +import { map$0vbopjd as option_map$0vbopjd } from "./core/option.ts"; + +/** + * The items `front..back`, read from either end, logging each call of its methods: `n`, + * `b`, `h`, and `l`, each with how many items it has left. + */ +export interface Run { + front: rt.u8; + back: rt.u8; + /** + * What `size_hint` adds to its upper bound, or `None` for none: past 0, it lies, and + * std's `len` of it panics. + */ + over: rt.u8 | undefined; + log: rt.RefCell; +} + +export function left(self: Run): rt.u8 { + return rt.u8Sub(self.back, self.front); +} + +export function logged(self: Run, what: rt.u8): void { + const _6: rt.RefCell = rt.refCellBorrowMut(self.log); + const _7: Uint8Array = Uint8Array.of(what, left(self)); + rt.iterExtendBytes(_6.value, rt.iterSlice(_7), undefined, true); + rt.refMutRelease(_6); +} + +export function next$iter_Iterator(self: Run): rt.u8 | rt.Done { + logged(self, 110); + if (!(self.front === self.back)) { + self.front = rt.u8Add(self.front, 1); + return rt.u8Sub(self.front, 1); + } + return rt.DONE; +} + +export function sizeHint$iter_Iterator(self: Run): [rt.usize, rt.usize | undefined] { + logged(self, 104); + const left_: rt.usize = left(self) as rt.usize; + const _5: rt.usize | undefined = option_map$0vbopjd(self.over, (over: rt.u8): rt.usize => { + return rt.usizeAdd(left_, over as rt.usize); + }); + return [left_, _5] as [rt.usize, rt.usize | undefined]; +} + +export function nextBack$iter_DoubleEndedIterator(self: Run): rt.u8 | undefined { + logged(self, 98); + if (!(self.front === self.back)) { + self.back = rt.u8Sub(self.back, 1); + return self.back; + } + return undefined; +} + +//# sourceMappingURL=ends.Run.ts.map diff --git a/ts/fixtures/lang/expected/ends.ts b/ts/fixtures/lang/expected/ends.ts new file mode 100644 index 000000000..1b0f0e174 --- /dev/null +++ b/ts/fixtures/lang/expected/ends.ts @@ -0,0 +1,270 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "./rt.ts"; +import { unwrapOr$0r2bmpr as option_unwrapOr$0r2bmpr, map$05nbzug as option_map$05nbzug, mapOr$02k4ito as option_mapOr$02k4ito } from "./core/option.ts"; +import * as ends_Counted from "./ends.Counted.ts"; +import * as Flicker from "./ends.Flicker.ts"; +import * as Lapse from "./ends.Lapse.ts"; +import * as ends_Run from "./ends.Run.ts"; + +/** An item, or 0xff for `None`. */ +export function put(out: rt.ByteVec, item: rt.u8 | undefined): void { + rt.byteVecPush(out, option_unwrapOr$0r2bmpr(item, 255)); +} + +/** A hint, the upper bound 0xff for `None`. */ +export function putHint(out: rt.ByteVec, _2: [rt.usize, rt.usize | undefined]): void { + const lower: rt.usize = _2[0]; + const upper: rt.usize | undefined = _2[1]; + rt.byteVecPush(out, lower & 0xff); + rt.byteVecPush(out, option_mapOr$02k4ito(upper, 255, (upper2: rt.usize): rt.u8 => { + return upper2 & 0xff; + })); +} + +/** + * A `Vec` collected or extended by `items`, by its length and capacity: what std reserved + * by their hints. + */ +export function putVec(out: rt.ByteVec, v: rt.ByteVec): void { + rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(v.length & 0xff, v.data.length & 0xff)), undefined, true); + rt.iterExtendBytes(out, rt.iterSlice(rt.byteVecView(v)), undefined, true); +} + +/** + * The run `data`'s first byte picks steps through with each of its other bytes, read + * directly, through `&mut`, or by std's adaptors, and consumed by the third byte's pick, + * with what each read and each call of its methods logged. + */ +export function ends(kind: rt.u8, dataData: Uint8Array, dataStart: number, dataLen: number, out: rt.ByteVec): void { + let over!: rt.u8 | undefined; + let item!: rt.u8 | undefined; + if (dataLen >= 2) { + const log: rt.RefCell = new rt.RefCell(new rt.ByteVec()); + const over2: rt.u8 = rt.u8Shr(dataData[dataStart], 4) & 3; + if (over2 === 0) { + over = undefined; + } else { + over = rt.u8Sub(over2, 1); + } + const run: ends_Run.Run = { front: 0, back: rt.u8Rem(dataData[dataStart], 16), over, log }; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2))), 8); + while (true) { + const _25: rt.u8 | rt.Done = iter.next(); + if (_25 === rt.DONE) { + break; + } + const step: rt.u8 = _25; + const _29: rt.u8 = rt.u8Rem(step, 8); + if (_29 === 0) { + put(out, rt.iterToOption(ends_Run.next$iter_Iterator(run))); + } else if (_29 === 1) { + put(out, ends_Run.nextBack$iter_DoubleEndedIterator(run)); + } else if (_29 === 2) { + const _37: rt.usize = rt.usizeRem(step >> 3 as rt.usize, 4); + put(out, rt.iterNthBack(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _37)); + } else if (_29 === 3) { + rt.byteVecPush(out, rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len() & 0xff); + } else if (_29 === 4) { + putHint(out, ends_Run.sizeHint$iter_Iterator(run)); + } else if (_29 === 5) { + put(out, rt.iterToOption(rt.iterRev(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))).next())); + } else if (_29 === 6) { + rt.byteVecPush(out, rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len() & 0xff); + } else { + const _58: rt.usize = rt.usizeRem(step >> 3 as rt.usize, 4); + put(out, rt.iterNth(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _58)); + } + } + const k: rt.usize = rt.u8Shr(dataData[dataStart + 1], 4) as rt.usize; + b4: { + const _67: rt.u8 = rt.u8Rem(kind, 4); + if (_67 === 0) { + consumed$ends_Run(run, rt.u8Rem(dataData[dataStart + 1], 16), k, out); + } else if (_67 === 1) { + consumed$ends_Counted({ _0: run }, rt.u8Rem(dataData[dataStart + 1], 16), k, out); + } else if (_67 === 2) { + fuses(dataData[dataStart + 1], out); + } else { + let bits: rt.u8 = dataData[dataStart + 1]; + while (true) { + if ((bits & 1) === 0) { + item = rt.iterToOption(ends_Run.next$iter_Iterator(run)); + } else { + item = ends_Run.nextBack$iter_DoubleEndedIterator(run); + } + bits = rt.intRotateRight(bits, 1, 8, false); + put(out, item); + if (item === undefined) { + put(out, ends_Run.nextBack$iter_DoubleEndedIterator(run)); + break b4; + } + } + } + } + rt.byteVecPush(out, 254); + rt.iterExtendBytes(out, rt.iterSlice(rt.byteVecView(log.value)), undefined, true); + } +} + +/** `it`, consumed by std's adaptor or consumer `pick`, with `k` its count where it takes one. */ +export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: rt.usize, out: rt.ByteVec): void { + if (pick === 0) { + putVec(out, rt.iterToByteVec(rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))), "next")); + } else if (pick === 1) { + putVec(out, rt.iterToByteVec(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), "next")); + } else if (pick === 2) { + rt.byteVecPush(out, rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))).len() & 0xff); + } else if (pick === 3) { + rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)))), (_2: [rt.usize, rt.u8]): Uint8Array => { + return Uint8Array.of(_2[0] & 0xff, _2[1]); + }, (value: Uint8Array) => rt.iterSlice(value), false, 2), "next"); + } else if (pick === 4) { + rt.iterExtendBytes(out, rt.iterRev(rt.iterSkip(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k)), "next"); + } else if (pick === 5) { + rt.iterExtendBytes(out, rt.iterRev(rt.iterTake(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k)), "next"); + } else if (pick === 6) { + const _27: ends_Counted.Counted = it; + const _28: rt.usize = rt.max(k, 1); + rt.iterExtendBytes(out, rt.iterRev(rt.iterStepBy(rt.iterFrom(_27, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), _28)), "next"); + } else if (pick === 7) { + put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b4: rt.u8): boolean => { + return rt.u8Rem(b4, 3) === 0; + }), (i: rt.usize): rt.u8 => { + return i & 0xff; + })); + } else if (pick === 8) { + put(out, rt.iterRfind(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b3: rt.u8): boolean => { + return rt.u8Rem(b3, 3) === 0; + })); + } else if (pick === 9) { + put(out, rt.iterLast(rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))))); + } else if (pick === 10) { + rt.iterExtendBytes(out, rt.iterTake(rt.iterRev(rt.iterMap(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b2: rt.u8): rt.u8 => { + return b2 ^ 85; + })), k), "next"); + } else if (pick === 11) { + const v: rt.ByteVec = rt.byteVecFrom(Uint8Array.of(170)); + const _45: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k); + rt.iterExtendBytes(v, _45, "next"); + putVec(out, v); + rt.byteVecPush(out, ends_Counted.len$iter_ExactSizeIterator(it) & 0xff); + } else if (pick === 12) { + const zip: rt.Iter<[rt.u8, rt.u8]> = rt.iterZip(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), new rt.Range(0, 5)); + while (true) { + const _57: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); + if (_57 !== undefined) { + rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_57[0], _57[1])), undefined, true); + } else { + break; + } + } + } else if (pick === 13) { + const fused: rt.Iter = rt.iterFuse(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))); + put(out, rt.iterToOption(fused.nextBack())); + rt.byteVecPush(out, fused.len() & 0xff); + rt.iterExtendBytes(out, fused, "next"); + } else if (pick === 14) { + put(out, rt.iterNth(rt.iterRev(rt.iterChain(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), rt.iterSlice(Uint8Array.of(7, 8)))), k)); + } else { + const peek: rt.Peekable = rt.iterPeekable(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))); + put(out, rt.peekablePeek(peek)); + rt.byteVecPush(out, peek.len() & 0xff); + rt.iterExtendBytes(out, rt.iterRev(peek), "next"); + } +} + +/** `it`, consumed by std's adaptor or consumer `pick`, with `k` its count where it takes one. */ +export function consumed$ends_Run(it: ends_Run.Run, pick: rt.u8, k: rt.usize, out: rt.ByteVec): void { + if (pick === 0) { + putVec(out, rt.iterToByteVec(rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))), "next")); + } else if (pick === 1) { + putVec(out, rt.iterToByteVec(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), "next")); + } else if (pick === 2) { + rt.byteVecPush(out, rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))).len() & 0xff); + } else if (pick === 3) { + rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))))), (_2: [rt.usize, rt.u8]): Uint8Array => { + return Uint8Array.of(_2[0] & 0xff, _2[1]); + }, (value: Uint8Array) => rt.iterSlice(value), false, 2), "next"); + } else if (pick === 4) { + rt.iterExtendBytes(out, rt.iterRev(rt.iterSkip(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k)), "next"); + } else if (pick === 5) { + rt.iterExtendBytes(out, rt.iterRev(rt.iterTake(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k)), "next"); + } else if (pick === 6) { + const _27: ends_Run.Run = it; + const _28: rt.usize = rt.max(k, 1); + rt.iterExtendBytes(out, rt.iterRev(rt.iterStepBy(rt.iterFrom(_27, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _28)), "next"); + } else if (pick === 7) { + put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b4: rt.u8): boolean => { + return rt.u8Rem(b4, 3) === 0; + }), (i: rt.usize): rt.u8 => { + return i & 0xff; + })); + } else if (pick === 8) { + put(out, rt.iterRfind(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b3: rt.u8): boolean => { + return rt.u8Rem(b3, 3) === 0; + })); + } else if (pick === 9) { + put(out, rt.iterLast(rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))))); + } else if (pick === 10) { + rt.iterExtendBytes(out, rt.iterTake(rt.iterRev(rt.iterMap(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b2: rt.u8): rt.u8 => { + return b2 ^ 85; + })), k), "next"); + } else if (pick === 11) { + const v: rt.ByteVec = rt.byteVecFrom(Uint8Array.of(170)); + const _45: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k); + rt.iterExtendBytes(v, _45, "next"); + putVec(out, v); + rt.byteVecPush(out, rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len() & 0xff); + } else if (pick === 12) { + const zip: rt.Iter<[rt.u8, rt.u8]> = rt.iterZip(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), new rt.Range(0, 5)); + while (true) { + const _57: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); + if (_57 !== undefined) { + rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_57[0], _57[1])), undefined, true); + } else { + break; + } + } + } else if (pick === 13) { + const fused: rt.Iter = rt.iterFuse(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))); + put(out, rt.iterToOption(fused.nextBack())); + rt.byteVecPush(out, fused.len() & 0xff); + rt.iterExtendBytes(out, fused, "next"); + } else if (pick === 14) { + put(out, rt.iterNth(rt.iterRev(rt.iterChain(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), rt.iterSlice(Uint8Array.of(7, 8)))), k)); + } else { + const peek: rt.Peekable = rt.iterPeekable(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))); + put(out, rt.peekablePeek(peek)); + rt.byteVecPush(out, peek.len() & 0xff); + rt.iterExtendBytes(out, rt.iterRev(peek), "next"); + } +} + +/** + * `fuse` of a `Flicker`, which reads on past its first `None`, or of a `Lapse`, which + * doesn't, read by the bits of `bits` from either end. + */ +export function fuses(bits: rt.u8, out: rt.ByteVec): void { + let _12!: rt.i32; + const start: rt.u8 = bits >> 4; + const fused: rt.Iter = rt.iterFuse(rt.iterFrom({ _0: start }, (it: Flicker.Flicker) => Flicker.next$iter_Iterator(it), undefined, undefined, (it: Flicker.Flicker) => rt.iterFromOption(Flicker.nextBack$iter_DoubleEndedIterator(it))), true); + let iterStart: rt.i32 = 0; + const iterEnd: rt.i32 = 6; + while ((_12 = iterStart++) < iterEnd) { + if ((rt.u8Shr(bits, rt.i32Rem(_12, 4)) & 1) === 0) { + put(out, rt.iterToOption(fused.next())); + } else { + put(out, rt.iterToOption(fused.nextBack())); + } + } + const lapsed: rt.Iter = rt.iterFuse(rt.iterFrom({ _0: { _0: start } }, (it: Lapse.Lapse) => Lapse.next$iter_Iterator(it))); + let iterStart2: rt.i32 = 0; + const iterEnd2: rt.i32 = 4; + while (iterStart2++ < iterEnd2) { + put(out, rt.iterToOption(lapsed.next())); + } + rt.iterExtendBytes(out, rt.iterSlice(rt.byteVecView(rt.iterToByteVec(rt.iterTake(rt.iterFlatten(rt.iterSlice([{ _0: start }, { _0: rt.u8WrappingAdd(start, 1) }]), (value: Flicker.Flicker) => rt.iterFrom(value, (it: Flicker.Flicker) => Flicker.next$iter_Iterator(it), undefined, undefined, (it: Flicker.Flicker) => rt.iterFromOption(Flicker.nextBack$iter_DoubleEndedIterator(it))), true), 5), "next"))), undefined, true); +} + +//# sourceMappingURL=ends.ts.map diff --git a/ts/fixtures/lang/expected/harness.ts b/ts/fixtures/lang/expected/harness.ts index a4b115d32..d04fc0dac 100644 --- a/ts/fixtures/lang/expected/harness.ts +++ b/ts/fixtures/lang/expected/harness.ts @@ -24,6 +24,7 @@ import { defaults as defaults_defaults } from "./defaults.ts"; import { durations } from "./durations.ts"; import { dyns, shared as dyns_shared, anys, fns } from "./dyns.ts"; import { edits as edits_edits, bytes as edits_bytes } from "./edits.ts"; +import { ends as ends_ends } from "./ends.ts"; import { eqs } from "./errors.ts"; import { fields as fields_fields } from "./fields.ts"; import { floats, mulAdds as floats_mulAdds, formats as floats_formats, parses as floats_parses } from "./floats.ts"; @@ -280,6 +281,8 @@ export function cases(): [string, (a0: rt.u8, a1: rt.ByteSlice, a2: rt.ByteVec) downgraded(data97, out98); }] as [string, (a0: rt.u8, a1: rt.ByteSlice, a2: rt.ByteVec) => undefined], ["borrows::leaks", (_2198: rt.u8, data98: rt.ByteSlice, out99: rt.ByteVec): undefined => { leaks(data98, out99); + }] as [string, (a0: rt.u8, a1: rt.ByteSlice, a2: rt.ByteVec) => undefined], ["ends::ends", (a0159: rt.u8, a1159: rt.ByteSlice, a2159: rt.ByteVec): undefined => { + ends_ends(a0159, a1159.data, a1159.start, a1159.length, a2159); }] as [string, (a0: rt.u8, a1: rt.ByteSlice, a2: rt.ByteVec) => undefined]]; } diff --git a/ts/fixtures/lang/src/ends.rs b/ts/fixtures/lang/src/ends.rs new file mode 100644 index 000000000..bf4beb67a --- /dev/null +++ b/ts/fixtures/lang/src/ends.rs @@ -0,0 +1,260 @@ +//! The crate's own iterators that read from the back, know their length, and say they stay +//! ended, with their own size hints: std's adaptors and consumers call each method where +//! native's do, and `fuse` reads on past the end of one that says it stays ended. + +use std::cell::RefCell; +use std::iter::FusedIterator; + +/// The items `front..back`, read from either end, logging each call of its methods: `n`, +/// `b`, `h`, and `l`, each with how many items it has left. +struct Run<'a> { + front: u8, + back: u8, + /// What `size_hint` adds to its upper bound, or `None` for none: past 0, it lies, and + /// std's `len` of it panics. + over: Option, + log: &'a RefCell>, +} + +impl Run<'_> { + fn left(&self) -> u8 { + self.back - self.front + } + + fn logged(&self, what: u8) { + self.log.borrow_mut().extend([what, self.left()]); + } +} + +impl Iterator for Run<'_> { + type Item = u8; + + fn next(&mut self) -> Option { + self.logged(b'n'); + if self.front == self.back { + return None; + } + self.front += 1; + Some(self.front - 1) + } + + fn size_hint(&self) -> (usize, Option) { + self.logged(b'h'); + let left = usize::from(self.left()); + (left, self.over.map(|over| left + usize::from(over))) + } +} + +impl DoubleEndedIterator for Run<'_> { + fn next_back(&mut self) -> Option { + self.logged(b'b'); + if self.front == self.back { + return None; + } + self.back -= 1; + Some(self.back) + } +} + +/// std's `len`, of its `size_hint`. +impl ExactSizeIterator for Run<'_> {} + +/// A `Run` whose `len` is its own, which reads the run's, as hashlink's `Values` does. +struct Counted<'a>(Run<'a>); + +impl Iterator for Counted<'_> { + type Item = u8; + + fn next(&mut self) -> Option { + self.0.next() + } + + fn size_hint(&self) -> (usize, Option) { + self.0.size_hint() + } +} + +impl DoubleEndedIterator for Counted<'_> { + fn next_back(&mut self) -> Option { + self.0.next_back() + } +} + +impl ExactSizeIterator for Counted<'_> { + fn len(&self) -> usize { + self.0.logged(b'l'); + self.0.len() + } +} + +/// Yields every other call to `next`, from either end, ending between: a `FusedIterator` +/// that isn't, which std's `fuse` reads on from as it would one that is. +struct Flicker(u8); + +impl Iterator for Flicker { + type Item = u8; + + fn next(&mut self) -> Option { + self.0 = self.0.wrapping_add(1); + (self.0 % 2 == 0).then_some(self.0) + } +} + +impl DoubleEndedIterator for Flicker { + fn next_back(&mut self) -> Option { + self.0 = self.0.wrapping_add(3); + (self.0 % 2 == 0).then_some(self.0) + } +} + +impl FusedIterator for Flicker {} + +/// As `Flicker`, without its `FusedIterator`, so std's `fuse` ends it at its first `None`. +struct Lapse(Flicker); + +impl Iterator for Lapse { + type Item = u8; + + fn next(&mut self) -> Option { + self.0.next() + } +} + +/// An item, or 0xff for `None`. +fn put(out: &mut Vec, item: Option) { + out.push(item.unwrap_or(0xff)); +} + +/// A hint, the upper bound 0xff for `None`. +fn put_hint(out: &mut Vec, (lower, upper): (usize, Option)) { + out.push(lower as u8); + out.push(upper.map_or(0xff, |upper| upper as u8)); +} + +/// A `Vec` collected or extended by `items`, by its length and capacity: what std reserved +/// by their hints. +fn put_vec(out: &mut Vec, v: Vec) { + out.extend([v.len() as u8, v.capacity() as u8]); + out.extend(v); +} + +/// The run `data`'s first byte picks steps through with each of its other bytes, read +/// directly, through `&mut`, or by std's adaptors, and consumed by the third byte's pick, +/// with what each read and each call of its methods logged. +pub fn ends(kind: u8, data: &[u8], out: &mut Vec) { + let [shape, consume, steps @ ..] = data else { + return; + }; + let log = RefCell::new(Vec::new()); + let over = match shape >> 4 & 3 { + 0 => None, + over => Some(over - 1), + }; + let mut run = Run { + front: 0, + back: shape % 16, + over, + log: &log, + }; + for &step in steps.iter().take(8) { + match step % 8 { + 0 => put(out, run.next()), + 1 => put(out, run.next_back()), + 2 => put(out, run.nth_back(usize::from(step >> 3) % 4)), + 3 => out.push(run.len() as u8), + 4 => put_hint(out, run.size_hint()), + 5 => put(out, (&mut run).rev().next()), + 6 => out.push((&mut run).len() as u8), + _ => put(out, run.nth(usize::from(step >> 3) % 4)), + } + } + let k = usize::from(consume >> 4); + match kind % 4 { + 0 => consumed(run, consume % 16, k, out), + 1 => consumed(Counted(run), consume % 16, k, out), + 2 => fuses(*consume, out), + _ => { + // Mixed from either end, by the bits of `consume`, until they meet. + let mut bits = *consume; + loop { + let item = match bits & 1 { + 0 => run.next(), + _ => run.next_back(), + }; + bits = bits.rotate_right(1); + put(out, item); + if item.is_none() { + break; + } + } + put(out, run.next_back()); + } + } + out.push(0xfe); + out.extend(log.into_inner()); +} + +/// `it`, consumed by std's adaptor or consumer `pick`, with `k` its count where it takes one. +fn consumed + ExactSizeIterator>(mut it: I, pick: u8, k: usize, out: &mut Vec) { + match pick { + 0 => put_vec(out, it.rev().collect()), + 1 => put_vec(out, it.collect()), + 2 => out.push(it.rev().len() as u8), + 3 => out.extend(it.enumerate().rev().flat_map(|(i, b)| [i as u8, b])), + 4 => out.extend(it.skip(k).rev()), + 5 => out.extend(it.take(k).rev()), + 6 => out.extend(it.step_by(k.max(1)).rev()), + 7 => put(out, it.rposition(|b| b % 3 == 0).map(|i| i as u8)), + 8 => put(out, it.skip(k % 4).rfind(|b| b % 3 == 0)), + 9 => put(out, it.rev().last()), + 10 => out.extend(it.map(|b| b ^ 0x55).rev().take(k)), + 11 => { + let mut v = vec![0xaa]; + v.extend(it.by_ref().take(k)); + put_vec(out, v); + out.push(it.len() as u8); + } + 12 => { + let mut zip = it.zip(0u8..5); + while let Some((a, b)) = zip.next_back() { + out.extend([a, b]); + } + } + 13 => { + let mut fused = it.fuse(); + put(out, fused.next_back()); + out.push(fused.len() as u8); + out.extend(fused); + } + 14 => put(out, it.chain([7, 8]).rev().nth(k)), + _ => { + let mut peek = it.peekable(); + put(out, peek.peek().copied()); + out.push(peek.len() as u8); + out.extend(peek.rev()); + } + } +} + +/// `fuse` of a `Flicker`, which reads on past its first `None`, or of a `Lapse`, which +/// doesn't, read by the bits of `bits` from either end. +fn fuses(bits: u8, out: &mut Vec) { + let start = bits >> 4; + let mut fused = Flicker(start).fuse(); + for k in 0..6 { + match bits >> (k % 4) & 1 { + 0 => put(out, fused.next()), + _ => put(out, fused.next_back()), + } + } + let mut lapsed = Lapse(Flicker(start)).fuse(); + for _ in 0..4 { + put(out, lapsed.next()); + } + let flat: Vec = [Flicker(start), Flicker(start.wrapping_add(1))] + .into_iter() + .flatten() + .take(5) + .collect(); + out.extend(flat); +} diff --git a/ts/fixtures/lang/src/harness.rs b/ts/fixtures/lang/src/harness.rs index 0a4253ba2..9d59c7279 100644 --- a/ts/fixtures/lang/src/harness.rs +++ b/ts/fixtures/lang/src/harness.rs @@ -3,10 +3,10 @@ use crate::{ args, arrays, ascii, atomics, borrows, bounds, boxes, capacity, captures, cells, chars, chunks, clones, - collections, combinators, conversions, counts, cows, cycles, defaults, durations, dyns, edits, errors, fields, - floats, fmt, folds, generics, hashes, hints, holds, ints, iters, joins, keys, lengths, lists, locals, locks, - methods, nested, objects, orders, pointers, refs, results, returns, saturates, separated, shapes, singles, slices, - splits, statics, strs, tuples, utf8, wrappers, wraps, zeros, + collections, combinators, conversions, counts, cows, cycles, defaults, durations, dyns, edits, ends, errors, + fields, floats, fmt, folds, generics, hashes, hints, holds, ints, iters, joins, keys, lengths, lists, locals, + locks, methods, nested, objects, orders, pointers, refs, results, returns, saturates, separated, shapes, singles, + slices, splits, statics, strs, tuples, utf8, wrappers, wraps, zeros, }; /// The native side's entry: [`run`], except that a case starting with 0xff prints a @@ -288,6 +288,7 @@ fn cases() -> Vec<(&'static str, Case)> { ("capacity::maps", capacity::maps), ("locks::downgraded", |_, data, out| locks::downgraded(data, out)), ("borrows::leaks", |_, data, out| borrows::leaks(data, out)), + ("ends::ends", ends::ends), ] } diff --git a/ts/fixtures/lang/src/lib.rs b/ts/fixtures/lang/src/lib.rs index a5f78962a..a1be5cc44 100644 --- a/ts/fixtures/lang/src/lib.rs +++ b/ts/fixtures/lang/src/lib.rs @@ -17,7 +17,7 @@ //! slices, the order, equality, and //! hashes of bytes, ranges of `Bound`s and of the crate's own `RangeBounds`, the equality //! of `Result`s and std's errors, inclusive ranges read through each adaptor, iterators' -//! size hints, the capacity overflows collections reserving by them panic with, the +//! size hints, the crate's own iterators read from the back and by their length, the capacity overflows collections reserving by them panic with, the //! capacity of a `Vec`, `VecDeque`, and `BinaryHeap` as each grows and shrinks, tuples of //! collections collected and extended by their items, zero-sized values, which MIR //! never assigns, with std's impls of them, functions generic over an array's length, and @@ -61,6 +61,7 @@ mod defaults; mod durations; mod dyns; mod edits; +mod ends; mod errors; mod fields; mod floats; diff --git a/ts/fixtures/reject/census.md b/ts/fixtures/reject/census.md index 67e9a15d8..4f4e34f4c 100644 --- a/ts/fixtures/reject/census.md +++ b/ts/fixtures/reject/census.md @@ -1,87 +1,86 @@ # Census of `reject-fixture` -- Refusals: 231 -- Function instances: 293 +- Refusals: 229 +- Function instances: 289 - Generic functions no instance reached, lowered over their type parameters: 13 ## By construct | Count | Construct | First | | ---: | --- | --- | -| 49 | a raw pointer to `_` in `_`, which the crate may put another object in place of | fixtures/reject/src/lib.rs:608:10 | -| 25 | unsupported call to `_` | fixtures/reject/src/lib.rs:160:8 | -| 22 | a raw pointer to `_` in a variable assigned again while it may point there | fixtures/reject/src/lib.rs:616:10 | -| 15 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | fixtures/reject/src/lib.rs:1337:33 | -| 15 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | fixtures/reject/src/lib.rs:1655:18 | -| 5 | `_` with a mutable reference to a value JS copies, which its mapping would copy | fixtures/reject/src/lib.rs:1235:22 | -| 5 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | fixtures/reject/src/lib.rs:679:10 | -| 4 | a variant of `_`, which is not supported: either is the same JS string | fixtures/reject/src/lib.rs:331:2 | +| 49 | a raw pointer to `_` in `_`, which the crate may put another object in place of | fixtures/reject/src/lib.rs:579:10 | +| 25 | unsupported call to `_` | fixtures/reject/src/lib.rs:164:8 | +| 22 | a raw pointer to `_` in a variable assigned again while it may point there | fixtures/reject/src/lib.rs:587:10 | +| 15 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | fixtures/reject/src/lib.rs:1308:33 | +| 15 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | fixtures/reject/src/lib.rs:1626:18 | +| 5 | `_` with a mutable reference to a value JS copies, which its mapping would copy | fixtures/reject/src/lib.rs:1206:22 | +| 5 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | fixtures/reject/src/lib.rs:650:10 | +| 4 | a variant of `_`, which is not supported: either is the same JS string | fixtures/reject/src/lib.rs:302:2 | | 4 | an assignment through a reference to `_` | fixtures/reject/src/lib.rs:83:2 | | 3 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | fixtures/reject/src/lib.rs:21:4 | -| 3 | a copy of a closure that changes what it captured | fixtures/reject/src/lib.rs:224:14 | -| 3 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | fixtures/reject/src/lib.rs:2164:2 | +| 3 | a copy of a closure that changes what it captured | fixtures/reject/src/lib.rs:195:14 | +| 3 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | fixtures/reject/src/lib.rs:2135:2 | | 3 | replacing the value behind a reference to `_` | fixtures/reject/src/lib.rs:91:2 | | 3 | unsupported type `_` | fixtures/reject/src/lib.rs:7:14 | | 2 | `_` is not supported: its `None` and `Some` would both be `rt.None` | fixtures/reject/src/lib.rs:16:15 | | 2 | `_` of `_`, whose `None` is `rt.None`, which is not supported yet | fixtures/reject/src/lib.rs:37:4 | | 2 | `_`, a trait object of another crate's trait, which is not supported yet | fixtures/reject/src/lib.rs:11:16 | -| 2 | `_`, a trait object of the generic trait `_`, which is not supported yet | fixtures/reject/src/lib.rs:464:23 | -| 2 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | fixtures/reject/src/lib.rs:555:27 | -| 2 | a coercion to `_`, which is not supported yet | fixtures/reject/src/lib.rs:455:40 | -| 2 | a raw pointer to a place of `()`, which has no address of its own | fixtures/reject/src/lib.rs:728:15 | -| 2 | an iterator of the crate implementing `_`, which is not supported yet | fixtures/reject/src/lib.rs:145:1 | -| 2 | comparing pointers to `_`, each a place JS makes of its own | fixtures/reject/src/lib.rs:596:2 | +| 2 | `_`, a trait object of the generic trait `_`, which is not supported yet | fixtures/reject/src/lib.rs:435:23 | +| 2 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | fixtures/reject/src/lib.rs:526:27 | +| 2 | a coercion to `_`, which is not supported yet | fixtures/reject/src/lib.rs:426:40 | +| 2 | a raw pointer to a place of `()`, which has no address of its own | fixtures/reject/src/lib.rs:699:15 | +| 2 | comparing pointers to `_`, each a place JS makes of its own | fixtures/reject/src/lib.rs:567:2 | | 2 | overriding `_`, which std's adaptors call in place of `next` or beside it | fixtures/reject/src/lib.rs:125:2 | -| 2 | passing `_`, which drops, to `_`, which is not supported yet | fixtures/reject/src/lib.rs:326:4 | -| 2 | unsupported type `_` from another crate | fixtures/reject/src/lib.rs:438:32 | -| 1 | `Buf::copy_to_bytes` of `_`, a value JS copies, which is not supported | fixtures/reject/src/lib.rs:761:2 | -| 1 | `BufMut::put` of `_` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:394:2 | -| 1 | `BufMut::put` of `_` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:389:2 | -| 1 | `Bytes::from_owner` of `_`, which would drop with the last clone of what it makes, which is not supported | fixtures/reject/src/lib.rs:374:2 | -| 1 | `Extend` of `_` by `_`, whose `_` of `_` is not supported yet | fixtures/reject/src/lib.rs:1272:31 | +| 2 | passing `_`, which drops, to `_`, which is not supported yet | fixtures/reject/src/lib.rs:297:4 | +| 2 | unsupported type `_` from another crate | fixtures/reject/src/lib.rs:409:32 | +| 1 | `Buf::copy_to_bytes` of `_`, a value JS copies, which is not supported | fixtures/reject/src/lib.rs:732:2 | +| 1 | `BufMut::put` of `_` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:365:2 | +| 1 | `BufMut::put` of `_` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:360:2 | +| 1 | `Bytes::from_owner` of `_`, which would drop with the last clone of what it makes, which is not supported | fixtures/reject/src/lib.rs:345:2 | +| 1 | `Extend` of `_` by `_`, whose `_` of `_` is not supported yet | fixtures/reject/src/lib.rs:1243:31 | | 1 | `Pointer` formatting, as in `{:p}`, is not supported | fixtures/reject/src/lib.rs:49:2 | | 1 | `_` is not supported: its `Pending` and `Ready` would both be `rt.OuterPending` | fixtures/reject/src/lib.rs:72:20 | | 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `None` would be `rt.None` as `_` | fixtures/reject/src/lib.rs:31:2 | -| 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `Pending` would be `rt.OuterPending` as `_` | fixtures/reject/src/lib.rs:502:2 | -| 1 | `_` of `_` by `_`, which is not supported yet | fixtures/reject/src/lib.rs:253:6 | -| 1 | `_` of `_`, which is not supported yet | fixtures/reject/src/lib.rs:538:4 | -| 1 | `_`, which is not supported yet | fixtures/reject/src/lib.rs:261:9 | -| 1 | `_`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:383:6 | -| 1 | `clone_from` of `_`, whose items' `clone_from` is their own, which is not supported yet | fixtures/reject/src/lib.rs:2118:4 | -| 1 | `collect` of `_`, which sorts by `_`'s own `Ord`, of entries that drop, which is not supported yet | fixtures/reject/src/lib.rs:955:22 | +| 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `Pending` would be `rt.OuterPending` as `_` | fixtures/reject/src/lib.rs:473:2 | +| 1 | `_` of `_` by `_`, which is not supported yet | fixtures/reject/src/lib.rs:224:6 | +| 1 | `_` of `_`, which is not supported yet | fixtures/reject/src/lib.rs:509:4 | +| 1 | `_`, which is not supported yet | fixtures/reject/src/lib.rs:232:9 | +| 1 | `_`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported | fixtures/reject/src/lib.rs:354:6 | +| 1 | `clone_from` of `_`, whose items' `clone_from` is their own, which is not supported yet | fixtures/reject/src/lib.rs:2089:4 | +| 1 | `collect` of `_`, which sorts by `_`'s own `Ord`, of entries that drop, which is not supported yet | fixtures/reject/src/lib.rs:926:22 | | 1 | `fmt::Arguments` with a placeholder, or not made in place, written to `_`'s own `fmt::Write`, which is not supported yet: std splits what a placeholder writes into `write_str` calls the runtime does not make | fixtures/reject/src/lib.rs:55:10 | -| 1 | a `collect` in place of `_`, a zip std reads by index, holding values that drop, which is not supported yet | fixtures/reject/src/lib.rs:209:40 | -| 1 | a `skip` of `_`, a zip std reads by index, of items that drop, which is not supported yet | fixtures/reject/src/lib.rs:202:8 | +| 1 | a `collect` in place of `_`, a zip std reads by index, holding values that drop, which is not supported yet | fixtures/reject/src/lib.rs:180:40 | +| 1 | a `skip` of `_`, a zip std reads by index, of items that drop, which is not supported yet | fixtures/reject/src/lib.rs:173:8 | | 1 | a cast from `_` to `_` | fixtures/reject/src/lib.rs:68:2 | -| 1 | a cast from `_` to `_`, which reads the bytes of one type as another | fixtures/reject/src/lib.rs:1713:33 | -| 1 | a coercion of `_` to `_`, a pointer to a slice | fixtures/reject/src/lib.rs:1714:28 | -| 1 | a coercion to `_` | fixtures/reject/src/lib.rs:291:2 | -| 1 | a constant of type `_`, a pointer into memory translation can't name | fixtures/reject/src/lib.rs:778:3 | -| 1 | a dangling pointer to `_`, a value of no bytes made of more than structs and tuples | fixtures/reject/src/lib.rs:737:11 | +| 1 | a cast from `_` to `_`, which reads the bytes of one type as another | fixtures/reject/src/lib.rs:1684:33 | +| 1 | a coercion of `_` to `_`, a pointer to a slice | fixtures/reject/src/lib.rs:1685:28 | +| 1 | a coercion to `_` | fixtures/reject/src/lib.rs:262:2 | +| 1 | a constant of type `_`, a pointer into memory translation can't name | fixtures/reject/src/lib.rs:749:3 | +| 1 | a dangling pointer to `_`, a value of no bytes made of more than structs and tuples | fixtures/reject/src/lib.rs:708:11 | | 1 | a future of `_`, which can be `rt.Pending`, as the future's own `Pending` is | fixtures/reject/src/lib.rs:77:34 | -| 1 | a mapped guard of `_`, which JS can't write in place | fixtures/reject/src/lib.rs:2152:10 | -| 1 | a mutable reference into a `Result`'s payload, passed on or kept | fixtures/reject/src/lib.rs:362:12 | +| 1 | a mapped guard of `_`, which JS can't write in place | fixtures/reject/src/lib.rs:2123:10 | +| 1 | a mutable reference into a `Result`'s payload, passed on or kept | fixtures/reject/src/lib.rs:333:12 | | 1 | a mutable static, which any code may write | fixtures/reject/src/lib.rs:61:11 | -| 1 | a pointer's address, which JS has no counterpart of | fixtures/reject/src/lib.rs:560:17 | +| 1 | a pointer's address, which JS has no counterpart of | fixtures/reject/src/lib.rs:531:17 | | 1 | a printable type must implement `Display` or `Debug` | fixtures/reject/src/lib.rs:64:1 | -| 1 | a raw pointer to `_` behind a reference, which is the object and not where it is kept | fixtures/reject/src/lib.rs:577:10 | -| 1 | a reference through which a raw pointer may be made into `_` in an element, a payload, or a union field, which is not supported yet | fixtures/reject/src/lib.rs:1364:11 | +| 1 | a raw pointer to `_` behind a reference, which is the object and not where it is kept | fixtures/reject/src/lib.rs:548:10 | +| 1 | a reference through which a raw pointer may be made into `_` in an element, a payload, or a union field, which is not supported yet | fixtures/reject/src/lib.rs:1335:11 | | 1 | a scalar constant of type `_` | fixtures/reject/src/lib.rs:8:2 | -| 1 | a slice of one byte's place, which a byte slice can view only in an array of bytes | fixtures/reject/src/lib.rs:2158:2 | -| 1 | a trait object of `_`, which is not supported yet | fixtures/reject/src/lib.rs:481:26 | -| 1 | an upcast from `_` to `_`, which is not supported yet | fixtures/reject/src/lib.rs:532:32 | +| 1 | a slice of one byte's place, which a byte slice can view only in an array of bytes | fixtures/reject/src/lib.rs:2129:2 | +| 1 | a trait object of `_`, which is not supported yet | fixtures/reject/src/lib.rs:452:26 | +| 1 | an upcast from `_` to `_`, which is not supported yet | fixtures/reject/src/lib.rs:503:32 | | 1 | arithmetic on `_` | fixtures/reject/src/lib.rs:8:2 | -| 1 | comparing `_` | fixtures/reject/src/lib.rs:1712:41 | -| 1 | comparing `_` as a key, which is not supported yet | fixtures/reject/src/lib.rs:235:75 | -| 1 | comparing pointers to `_` in an atomic, which JS has no address of | fixtures/reject/src/lib.rs:777:15 | -| 1 | comparing pointers to `_`, which has no bytes and so no address of its own | fixtures/reject/src/lib.rs:728:70 | -| 1 | const generic types are not supported: `_` | fixtures/reject/src/lib.rs:2097:1 | -| 1 | constructing `_` | fixtures/reject/src/lib.rs:349:53 | -| 1 | hashing `_` as a key, which is not supported yet | fixtures/reject/src/lib.rs:235:75 | -| 1 | hashing `_` by its address, which JS has no counterpart of | fixtures/reject/src/lib.rs:1716:5 | -| 1 | hashing `_` through `_`'s own `Hash::hash_slice`, which is not supported yet | fixtures/reject/src/lib.rs:310:16 | -| 1 | passing `_`, a closure that owns a value that drops, to `_`, which is not supported yet | fixtures/reject/src/lib.rs:319:13 | -| 1 | union `_`, whose fields overlap in `_` and `f64`, which JS keeps apart | fixtures/reject/src/lib.rs:582:1 | +| 1 | comparing `_` | fixtures/reject/src/lib.rs:1683:41 | +| 1 | comparing `_` as a key, which is not supported yet | fixtures/reject/src/lib.rs:206:75 | +| 1 | comparing pointers to `_` in an atomic, which JS has no address of | fixtures/reject/src/lib.rs:748:15 | +| 1 | comparing pointers to `_`, which has no bytes and so no address of its own | fixtures/reject/src/lib.rs:699:70 | +| 1 | const generic types are not supported: `_` | fixtures/reject/src/lib.rs:2068:1 | +| 1 | constructing `_` | fixtures/reject/src/lib.rs:320:53 | +| 1 | hashing `_` as a key, which is not supported yet | fixtures/reject/src/lib.rs:206:75 | +| 1 | hashing `_` by its address, which JS has no counterpart of | fixtures/reject/src/lib.rs:1687:5 | +| 1 | hashing `_` through `_`'s own `Hash::hash_slice`, which is not supported yet | fixtures/reject/src/lib.rs:281:16 | +| 1 | passing `_`, a closure that owns a value that drops, to `_`, which is not supported yet | fixtures/reject/src/lib.rs:290:13 | +| 1 | union `_`, whose fields overlap in `_` and `f64`, which JS keeps apart | fixtures/reject/src/lib.rs:553:1 | ## By API @@ -89,169 +88,168 @@ The type or module each refused type or path belongs to. | Count | API | First | | ---: | --- | --- | -| 39 | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:687:15 | -| 27 | `(u32, u32)` | fixtures/reject/src/lib.rs:608:10 | -| 6 | `[u8; 4]` | fixtures/reject/src/lib.rs:481:26 | +| 39 | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:658:15 | +| 27 | `(u32, u32)` | fixtures/reject/src/lib.rs:579:10 | +| 6 | `[u8; 4]` | fixtures/reject/src/lib.rs:452:26 | | 6 | `f16` | fixtures/reject/src/lib.rs:7:14 | -| 6 | `std::borrow::Cow` | fixtures/reject/src/lib.rs:331:2 | -| 6 | `u32` | fixtures/reject/src/lib.rs:555:27 | -| 5 | `(u8, u8)` | fixtures/reject/src/lib.rs:1272:31 | -| 5 | `Gap` | fixtures/reject/src/lib.rs:908:10 | +| 6 | `std::borrow::Cow` | fixtures/reject/src/lib.rs:302:2 | +| 6 | `u32` | fixtures/reject/src/lib.rs:526:27 | +| 5 | `(u8, u8)` | fixtures/reject/src/lib.rs:1243:31 | +| 5 | `Gap` | fixtures/reject/src/lib.rs:879:10 | | 5 | `Option` | fixtures/reject/src/lib.rs:16:15 | -| 5 | `u8` | fixtures/reject/src/lib.rs:253:6 | -| 4 | `Iterator` | fixtures/reject/src/lib.rs:37:4 | +| 5 | `u8` | fixtures/reject/src/lib.rs:224:6 | | 4 | `std::pin::Pin` | fixtures/reject/src/lib.rs:91:2 | -| 4 | `std::str` | fixtures/reject/src/lib.rs:439:4 | -| 4 | `{closure}` | fixtures/reject/src/lib.rs:319:13 | -| 3 | `*const [u8; 4]` | fixtures/reject/src/lib.rs:1713:33 | -| 3 | `Mid` | fixtures/reject/src/lib.rs:1355:34 | -| 3 | `Outer` | fixtures/reject/src/lib.rs:1355:34 | +| 4 | `std::str` | fixtures/reject/src/lib.rs:410:4 | +| 4 | `{closure}` | fixtures/reject/src/lib.rs:290:13 | +| 3 | `*const [u8; 4]` | fixtures/reject/src/lib.rs:1684:33 | +| 3 | `Iterator` | fixtures/reject/src/lib.rs:37:4 | +| 3 | `Mid` | fixtures/reject/src/lib.rs:1326:34 | +| 3 | `Outer` | fixtures/reject/src/lib.rs:1326:34 | | 3 | `Reused` | fixtures/reject/src/lib.rs:21:4 | -| 3 | `std::ptr` | fixtures/reject/src/lib.rs:1710:3 | -| 3 | `std::vec::Vec` | fixtures/reject/src/lib.rs:310:16 | -| 2 | `(u16, u16)` | fixtures/reject/src/lib.rs:1176:31 | -| 2 | `Counted` | fixtures/reject/src/lib.rs:389:2 | -| 2 | `InArray` | fixtures/reject/src/lib.rs:1302:9 | -| 2 | `InPayload` | fixtures/reject/src/lib.rs:1314:9 | -| 2 | `InTuple` | fixtures/reject/src/lib.rs:1306:9 | -| 2 | `InWritten` | fixtures/reject/src/lib.rs:1326:9 | -| 2 | `Inside` | fixtures/reject/src/lib.rs:1845:20 | +| 3 | `std::ptr` | fixtures/reject/src/lib.rs:1681:3 | +| 3 | `std::vec::Vec` | fixtures/reject/src/lib.rs:281:16 | +| 2 | `(u16, u16)` | fixtures/reject/src/lib.rs:1147:31 | +| 2 | `Counted` | fixtures/reject/src/lib.rs:360:2 | +| 2 | `InArray` | fixtures/reject/src/lib.rs:1273:9 | +| 2 | `InPayload` | fixtures/reject/src/lib.rs:1285:9 | +| 2 | `InTuple` | fixtures/reject/src/lib.rs:1277:9 | +| 2 | `InWritten` | fixtures/reject/src/lib.rs:1297:9 | +| 2 | `Inside` | fixtures/reject/src/lib.rs:1816:20 | | 2 | `Poll` | fixtures/reject/src/lib.rs:72:20 | -| 2 | `Scaled` | fixtures/reject/src/lib.rs:464:23 | -| 2 | `[u8; 2]` | fixtures/reject/src/lib.rs:1726:37 | -| 2 | `[u8; 3]` | fixtures/reject/src/lib.rs:1726:15 | -| 2 | `dyn Scaled` | fixtures/reject/src/lib.rs:464:23 | -| 2 | `dyn std::any::Any` | fixtures/reject/src/lib.rs:532:32 | +| 2 | `Scaled` | fixtures/reject/src/lib.rs:435:23 | +| 2 | `[u8; 2]` | fixtures/reject/src/lib.rs:1697:37 | +| 2 | `[u8; 3]` | fixtures/reject/src/lib.rs:1697:15 | +| 2 | `dyn Scaled` | fixtures/reject/src/lib.rs:435:23 | +| 2 | `dyn std::any::Any` | fixtures/reject/src/lib.rs:503:32 | | 2 | `dyn std::iter::Iterator` | fixtures/reject/src/lib.rs:11:16 | | 2 | `slice` | fixtures/reject/src/lib.rs:21:4 | -| 2 | `std::any::TypeId` | fixtures/reject/src/lib.rs:538:2 | -| 2 | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:235:75 | -| 2 | `std::collections::LinkedList` | fixtures/reject/src/lib.rs:2117:4 | -| 2 | `std::mem::MaybeUninit` | fixtures/reject/src/lib.rs:922:19 | -| 2 | `std::ops::Range` | fixtures/reject/src/lib.rs:160:8 | -| 2 | `std::option::Option` | fixtures/reject/src/lib.rs:369:2 | -| 2 | `std::ptr::const_ptr` | fixtures/reject/src/lib.rs:1713:73 | -| 2 | `std::std` | fixtures/reject/src/lib.rs:567:11 | -| 2 | `std::sync::Arc` | fixtures/reject/src/lib.rs:291:2 | +| 2 | `std::any::TypeId` | fixtures/reject/src/lib.rs:509:2 | +| 2 | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:206:75 | +| 2 | `std::collections::LinkedList` | fixtures/reject/src/lib.rs:2088:4 | +| 2 | `std::mem::MaybeUninit` | fixtures/reject/src/lib.rs:893:19 | +| 2 | `std::ops::Range` | fixtures/reject/src/lib.rs:164:8 | +| 2 | `std::option::Option` | fixtures/reject/src/lib.rs:340:2 | +| 2 | `std::ptr::const_ptr` | fixtures/reject/src/lib.rs:1684:73 | +| 2 | `std::std` | fixtures/reject/src/lib.rs:538:11 | +| 2 | `std::sync::Arc` | fixtures/reject/src/lib.rs:262:2 | | 2 | `std::sync::MutexGuard` | fixtures/reject/src/lib.rs:83:2 | -| 2 | `std::vec::IntoIter` | fixtures/reject/src/lib.rs:434:17 | -| 1 | `(Dropped, (u8, u8))` | fixtures/reject/src/lib.rs:2263:2 | -| 1 | `([Cloned; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2247:2 | -| 1 | `([Greatest; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2281:13 | -| 1 | `([Touched; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2312:2 | -| 1 | `(std::vec::Vec, Tens)` | fixtures/reject/src/lib.rs:1272:31 | -| 1 | `(u16, ByKeyReplace)` | fixtures/reject/src/lib.rs:1621:55 | -| 1 | `(u16, ByKeySet)` | fixtures/reject/src/lib.rs:1613:51 | -| 1 | `(u16, ByKeyTake)` | fixtures/reject/src/lib.rs:1628:52 | -| 1 | `(u16, ByRefReplace)` | fixtures/reject/src/lib.rs:1597:32 | -| 1 | `(u16, ByRefTake)` | fixtures/reject/src/lib.rs:1605:32 | -| 1 | `(u16, InTuple)` | fixtures/reject/src/lib.rs:1346:33 | -| 1 | `*const [u8]` | fixtures/reject/src/lib.rs:1714:28 | -| 1 | `*const u8` | fixtures/reject/src/lib.rs:1713:33 | -| 1 | `*mut [u8; 4]` | fixtures/reject/src/lib.rs:1712:41 | -| 1 | `Aliased` | fixtures/reject/src/lib.rs:1120:29 | -| 1 | `Assigned` | fixtures/reject/src/lib.rs:2012:20 | -| 1 | `Batched` | fixtures/reject/src/lib.rs:310:16 | -| 1 | `Behind` | fixtures/reject/src/lib.rs:1751:22 | -| 1 | `Bits` | fixtures/reject/src/lib.rs:582:1 | -| 1 | `Blank` | fixtures/reject/src/lib.rs:761:2 | -| 1 | `Block` | fixtures/reject/src/lib.rs:2097:1 | -| 1 | `ByBox` | fixtures/reject/src/lib.rs:1504:35 | -| 1 | `ByClosure` | fixtures/reject/src/lib.rs:1519:35 | -| 1 | `ByExchanged` | fixtures/reject/src/lib.rs:1565:30 | -| 1 | `ByInstance` | fixtures/reject/src/lib.rs:1545:35 | -| 1 | `ByKeyReplace` | fixtures/reject/src/lib.rs:1621:55 | -| 1 | `ByKeySet` | fixtures/reject/src/lib.rs:1613:51 | -| 1 | `ByKeyTake` | fixtures/reject/src/lib.rs:1628:52 | -| 1 | `ByObject` | fixtures/reject/src/lib.rs:1532:35 | -| 1 | `ByRead` | fixtures/reject/src/lib.rs:1455:35 | -| 1 | `ByRefReplace` | fixtures/reject/src/lib.rs:1597:32 | -| 1 | `ByRefTake` | fixtures/reject/src/lib.rs:1605:32 | -| 1 | `ByReplace` | fixtures/reject/src/lib.rs:1493:35 | -| 1 | `BySwap` | fixtures/reject/src/lib.rs:1481:35 | -| 1 | `BySwapped` | fixtures/reject/src/lib.rs:1554:76 | -| 1 | `ByWrite` | fixtures/reject/src/lib.rs:1468:35 | -| 1 | `BytesMut` | fixtures/reject/src/lib.rs:383:6 | -| 1 | `Called` | fixtures/reject/src/lib.rs:1086:28 | -| 1 | `Chosen` | fixtures/reject/src/lib.rs:1906:17 | -| 1 | `Clone` | fixtures/reject/src/lib.rs:2169:4 | -| 1 | `Closed` | fixtures/reject/src/lib.rs:2078:15 | -| 1 | `Compared` | fixtures/reject/src/lib.rs:1873:22 | -| 1 | `Copied` | fixtures/reject/src/lib.rs:1176:31 | -| 1 | `Deep` | fixtures/reject/src/lib.rs:1787:18 | -| 1 | `Deeper` | fixtures/reject/src/lib.rs:2038:22 | -| 1 | `DoubleEndedIterator` | fixtures/reject/src/lib.rs:145:1 | -| 1 | `Dynamic` | fixtures/reject/src/lib.rs:2062:20 | -| 1 | `Enclosing` | fixtures/reject/src/lib.rs:1890:22 | -| 1 | `Entry` | fixtures/reject/src/lib.rs:319:13 | -| 1 | `Escaped` | fixtures/reject/src/lib.rs:1072:43 | -| 1 | `FusedIterator` | fixtures/reject/src/lib.rs:193:1 | -| 1 | `Fused` | fixtures/reject/src/lib.rs:728:70 | -| 1 | `HashMap` | fixtures/reject/src/lib.rs:253:6 | -| 1 | `Hasher` | fixtures/reject/src/lib.rs:261:9 | -| 1 | `Hits` | fixtures/reject/src/lib.rs:720:21 | -| 1 | `InField` | fixtures/reject/src/lib.rs:1318:9 | -| 1 | `InGeneric` | fixtures/reject/src/lib.rs:1322:9 | -| 1 | `InNested` | fixtures/reject/src/lib.rs:1310:9 | -| 1 | `Lane` | fixtures/reject/src/lib.rs:872:19 | -| 1 | `Loaded` | fixtures/reject/src/lib.rs:1142:29 | -| 1 | `Looped` | fixtures/reject/src/lib.rs:1110:26 | -| 1 | `Mapped` | fixtures/reject/src/lib.rs:1187:39 | +| 2 | `std::vec::IntoIter` | fixtures/reject/src/lib.rs:405:17 | +| 1 | `(Dropped, (u8, u8))` | fixtures/reject/src/lib.rs:2234:2 | +| 1 | `([Cloned; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2218:2 | +| 1 | `([Greatest; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2252:13 | +| 1 | `([Touched; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2283:2 | +| 1 | `(std::vec::Vec, Tens)` | fixtures/reject/src/lib.rs:1243:31 | +| 1 | `(u16, ByKeyReplace)` | fixtures/reject/src/lib.rs:1592:55 | +| 1 | `(u16, ByKeySet)` | fixtures/reject/src/lib.rs:1584:51 | +| 1 | `(u16, ByKeyTake)` | fixtures/reject/src/lib.rs:1599:52 | +| 1 | `(u16, ByRefReplace)` | fixtures/reject/src/lib.rs:1568:32 | +| 1 | `(u16, ByRefTake)` | fixtures/reject/src/lib.rs:1576:32 | +| 1 | `(u16, InTuple)` | fixtures/reject/src/lib.rs:1317:33 | +| 1 | `*const [u8]` | fixtures/reject/src/lib.rs:1685:28 | +| 1 | `*const u8` | fixtures/reject/src/lib.rs:1684:33 | +| 1 | `*mut [u8; 4]` | fixtures/reject/src/lib.rs:1683:41 | +| 1 | `Aliased` | fixtures/reject/src/lib.rs:1091:29 | +| 1 | `Assigned` | fixtures/reject/src/lib.rs:1983:20 | +| 1 | `Bare` | fixtures/reject/src/lib.rs:699:70 | +| 1 | `Batched` | fixtures/reject/src/lib.rs:281:16 | +| 1 | `Behind` | fixtures/reject/src/lib.rs:1722:22 | +| 1 | `Bits` | fixtures/reject/src/lib.rs:553:1 | +| 1 | `Blank` | fixtures/reject/src/lib.rs:732:2 | +| 1 | `Block` | fixtures/reject/src/lib.rs:2068:1 | +| 1 | `ByBox` | fixtures/reject/src/lib.rs:1475:35 | +| 1 | `ByClosure` | fixtures/reject/src/lib.rs:1490:35 | +| 1 | `ByExchanged` | fixtures/reject/src/lib.rs:1536:30 | +| 1 | `ByInstance` | fixtures/reject/src/lib.rs:1516:35 | +| 1 | `ByKeyReplace` | fixtures/reject/src/lib.rs:1592:55 | +| 1 | `ByKeySet` | fixtures/reject/src/lib.rs:1584:51 | +| 1 | `ByKeyTake` | fixtures/reject/src/lib.rs:1599:52 | +| 1 | `ByObject` | fixtures/reject/src/lib.rs:1503:35 | +| 1 | `ByRead` | fixtures/reject/src/lib.rs:1426:35 | +| 1 | `ByRefReplace` | fixtures/reject/src/lib.rs:1568:32 | +| 1 | `ByRefTake` | fixtures/reject/src/lib.rs:1576:32 | +| 1 | `ByReplace` | fixtures/reject/src/lib.rs:1464:35 | +| 1 | `BySwap` | fixtures/reject/src/lib.rs:1452:35 | +| 1 | `BySwapped` | fixtures/reject/src/lib.rs:1525:76 | +| 1 | `ByWrite` | fixtures/reject/src/lib.rs:1439:35 | +| 1 | `BytesMut` | fixtures/reject/src/lib.rs:354:6 | +| 1 | `Called` | fixtures/reject/src/lib.rs:1057:28 | +| 1 | `Chosen` | fixtures/reject/src/lib.rs:1877:17 | +| 1 | `Clone` | fixtures/reject/src/lib.rs:2140:4 | +| 1 | `Closed` | fixtures/reject/src/lib.rs:2049:15 | +| 1 | `Compared` | fixtures/reject/src/lib.rs:1844:22 | +| 1 | `Copied` | fixtures/reject/src/lib.rs:1147:31 | +| 1 | `Deep` | fixtures/reject/src/lib.rs:1758:18 | +| 1 | `Deeper` | fixtures/reject/src/lib.rs:2009:22 | +| 1 | `DoubleEndedIterator` | fixtures/reject/src/lib.rs:150:2 | +| 1 | `Dynamic` | fixtures/reject/src/lib.rs:2033:20 | +| 1 | `Enclosing` | fixtures/reject/src/lib.rs:1861:22 | +| 1 | `Entry` | fixtures/reject/src/lib.rs:290:13 | +| 1 | `Escaped` | fixtures/reject/src/lib.rs:1043:43 | +| 1 | `HashMap` | fixtures/reject/src/lib.rs:224:6 | +| 1 | `Hasher` | fixtures/reject/src/lib.rs:232:9 | +| 1 | `Hits` | fixtures/reject/src/lib.rs:691:21 | +| 1 | `InField` | fixtures/reject/src/lib.rs:1289:9 | +| 1 | `InGeneric` | fixtures/reject/src/lib.rs:1293:9 | +| 1 | `InNested` | fixtures/reject/src/lib.rs:1281:9 | +| 1 | `Lane` | fixtures/reject/src/lib.rs:843:19 | +| 1 | `Loaded` | fixtures/reject/src/lib.rs:1113:29 | +| 1 | `Looped` | fixtures/reject/src/lib.rs:1081:26 | +| 1 | `Mapped` | fixtures/reject/src/lib.rs:1158:39 | | 1 | `Maybe` | fixtures/reject/src/lib.rs:31:2 | -| 1 | `Onced` | fixtures/reject/src/lib.rs:1233:46 | -| 1 | `Only` | fixtures/reject/src/lib.rs:737:11 | -| 1 | `Parked` | fixtures/reject/src/lib.rs:2137:20 | -| 1 | `Parking` | fixtures/reject/src/lib.rs:2137:20 | -| 1 | `Plain` | fixtures/reject/src/lib.rs:826:10 | -| 1 | `Pushed` | fixtures/reject/src/lib.rs:1248:22 | -| 1 | `Repeated` | fixtures/reject/src/lib.rs:1221:18 | -| 1 | `Replaced` | fixtures/reject/src/lib.rs:1957:20 | -| 1 | `Rewritten` | fixtures/reject/src/lib.rs:1130:47 | -| 1 | `Shared` | fixtures/reject/src/lib.rs:1828:20 | +| 1 | `Onced` | fixtures/reject/src/lib.rs:1204:46 | +| 1 | `Only` | fixtures/reject/src/lib.rs:708:11 | +| 1 | `Parked` | fixtures/reject/src/lib.rs:2108:20 | +| 1 | `Parking` | fixtures/reject/src/lib.rs:2108:20 | +| 1 | `Plain` | fixtures/reject/src/lib.rs:797:10 | +| 1 | `Pushed` | fixtures/reject/src/lib.rs:1219:22 | +| 1 | `Repeated` | fixtures/reject/src/lib.rs:1192:18 | +| 1 | `Replaced` | fixtures/reject/src/lib.rs:1928:20 | +| 1 | `Rewritten` | fixtures/reject/src/lib.rs:1101:47 | +| 1 | `Shared` | fixtures/reject/src/lib.rs:1799:20 | | 1 | `Sink` | fixtures/reject/src/lib.rs:55:10 | -| 1 | `Slotted` | fixtures/reject/src/lib.rs:1809:21 | -| 1 | `Span2` | fixtures/reject/src/lib.rs:608:10 | -| 1 | `String` | fixtures/reject/src/lib.rs:784:4 | -| 1 | `Swapped` | fixtures/reject/src/lib.rs:1975:20 | +| 1 | `Slotted` | fixtures/reject/src/lib.rs:1780:21 | +| 1 | `Span2` | fixtures/reject/src/lib.rs:579:10 | +| 1 | `String` | fixtures/reject/src/lib.rs:755:4 | +| 1 | `Swapped` | fixtures/reject/src/lib.rs:1946:20 | | 1 | `T \| undefined` | fixtures/reject/src/lib.rs:31:2 | -| 1 | `Tail` | fixtures/reject/src/lib.rs:491:30 | -| 1 | `Taken` | fixtures/reject/src/lib.rs:1993:20 | -| 1 | `Target` | fixtures/reject/src/lib.rs:1669:10 | -| 1 | `Tens` | fixtures/reject/src/lib.rs:1272:31 | -| 1 | `Track` | fixtures/reject/src/lib.rs:852:19 | -| 1 | `Unboxed` | fixtures/reject/src/lib.rs:1766:16 | -| 1 | `Waiting` | fixtures/reject/src/lib.rs:502:2 | -| 1 | `Window` | fixtures/reject/src/lib.rs:669:2 | -| 1 | `Wrapped` | fixtures/reject/src/lib.rs:1934:21 | -| 1 | `[InArray; 2]` | fixtures/reject/src/lib.rs:1337:33 | -| 1 | `[InWritten; 1]` | fixtures/reject/src/lib.rs:1398:35 | -| 1 | `[std::cell::UnsafeCell; 2]` | fixtures/reject/src/lib.rs:2091:20 | -| 1 | `dyn Keyed` | fixtures/reject/src/lib.rs:532:32 | -| 1 | `poll` | fixtures/reject/src/lib.rs:502:2 | -| 1 | `rt.Poll` | fixtures/reject/src/lib.rs:502:2 | -| 1 | `std::any::Any` | fixtures/reject/src/lib.rs:538:4 | -| 1 | `std::cell::Cell` | fixtures/reject/src/lib.rs:955:22 | -| 1 | `std::cell::LazyCell` | fixtures/reject/src/lib.rs:2206:3 | -| 1 | `std::collections::BTreeMap` | fixtures/reject/src/lib.rs:955:22 | -| 1 | `std::collections::HashMap` | fixtures/reject/src/lib.rs:253:6 | -| 1 | `std::default::Default` | fixtures/reject/src/lib.rs:2119:2 | -| 1 | `std::iter::Map` | fixtures/reject/src/lib.rs:209:40 | -| 1 | `std::iter::Zip` | fixtures/reject/src/lib.rs:202:8 | -| 1 | `std::iter` | fixtures/reject/src/lib.rs:1235:22 | -| 1 | `std::mem` | fixtures/reject/src/lib.rs:2174:2 | -| 1 | `std::net::AddrParseError` | fixtures/reject/src/lib.rs:438:32 | -| 1 | `std::net::Ipv4Addr` | fixtures/reject/src/lib.rs:438:32 | -| 1 | `std::num` | fixtures/reject/src/lib.rs:1277:4 | -| 1 | `std::ops::RangeFrom` | fixtures/reject/src/lib.rs:984:32 | -| 1 | `std::ops::RangeTo` | fixtures/reject/src/lib.rs:984:11 | -| 1 | `std::ptr::mut_ptr` | fixtures/reject/src/lib.rs:1713:56 | -| 1 | `std::slice::IterMut` | fixtures/reject/src/lib.rs:766:15 | -| 1 | `std::std::Layout` | fixtures/reject/src/lib.rs:565:15 | -| 1 | `std::sync::LazyLock` | fixtures/reject/src/lib.rs:2211:2 | -| 1 | `std::sync::Weak` | fixtures/reject/src/lib.rs:455:40 | +| 1 | `Tail` | fixtures/reject/src/lib.rs:462:30 | +| 1 | `Taken` | fixtures/reject/src/lib.rs:1964:20 | +| 1 | `Target` | fixtures/reject/src/lib.rs:1640:10 | +| 1 | `Tens` | fixtures/reject/src/lib.rs:1243:31 | +| 1 | `Track` | fixtures/reject/src/lib.rs:823:19 | +| 1 | `Unboxed` | fixtures/reject/src/lib.rs:1737:16 | +| 1 | `Waiting` | fixtures/reject/src/lib.rs:473:2 | +| 1 | `Window` | fixtures/reject/src/lib.rs:640:2 | +| 1 | `Wrapped` | fixtures/reject/src/lib.rs:1905:21 | +| 1 | `[InArray; 2]` | fixtures/reject/src/lib.rs:1308:33 | +| 1 | `[InWritten; 1]` | fixtures/reject/src/lib.rs:1369:35 | +| 1 | `[std::cell::UnsafeCell; 2]` | fixtures/reject/src/lib.rs:2062:20 | +| 1 | `dyn Keyed` | fixtures/reject/src/lib.rs:503:32 | +| 1 | `poll` | fixtures/reject/src/lib.rs:473:2 | +| 1 | `rt.Poll` | fixtures/reject/src/lib.rs:473:2 | +| 1 | `std::any::Any` | fixtures/reject/src/lib.rs:509:4 | +| 1 | `std::cell::Cell` | fixtures/reject/src/lib.rs:926:22 | +| 1 | `std::cell::LazyCell` | fixtures/reject/src/lib.rs:2177:3 | +| 1 | `std::collections::BTreeMap` | fixtures/reject/src/lib.rs:926:22 | +| 1 | `std::collections::HashMap` | fixtures/reject/src/lib.rs:224:6 | +| 1 | `std::default::Default` | fixtures/reject/src/lib.rs:2090:2 | +| 1 | `std::iter::Map` | fixtures/reject/src/lib.rs:180:40 | +| 1 | `std::iter::Zip` | fixtures/reject/src/lib.rs:173:8 | +| 1 | `std::iter` | fixtures/reject/src/lib.rs:1206:22 | +| 1 | `std::mem` | fixtures/reject/src/lib.rs:2145:2 | +| 1 | `std::net::AddrParseError` | fixtures/reject/src/lib.rs:409:32 | +| 1 | `std::net::Ipv4Addr` | fixtures/reject/src/lib.rs:409:32 | +| 1 | `std::num` | fixtures/reject/src/lib.rs:1248:4 | +| 1 | `std::ops::RangeFrom` | fixtures/reject/src/lib.rs:955:32 | +| 1 | `std::ops::RangeTo` | fixtures/reject/src/lib.rs:955:11 | +| 1 | `std::ptr::mut_ptr` | fixtures/reject/src/lib.rs:1684:56 | +| 1 | `std::slice::IterMut` | fixtures/reject/src/lib.rs:737:15 | +| 1 | `std::std::Layout` | fixtures/reject/src/lib.rs:536:15 | +| 1 | `std::sync::LazyLock` | fixtures/reject/src/lib.rs:2182:2 | +| 1 | `std::sync::Weak` | fixtures/reject/src/lib.rs:426:40 | | 1 | `std::task::Poll` | fixtures/reject/src/lib.rs:77:34 | -| 1 | `std::thread::LocalKey` | fixtures/reject/src/lib.rs:2217:2 | -| 1 | `str` | fixtures/reject/src/lib.rs:326:4 | +| 1 | `std::thread::LocalKey` | fixtures/reject/src/lib.rs:2188:2 | +| 1 | `str` | fixtures/reject/src/lib.rs:297:4 | | 1 | `u64` | fixtures/reject/src/lib.rs:68:2 | | 1 | `value` | fixtures/reject/src/lib.rs:31:2 | @@ -259,366 +257,364 @@ The type or module each refused type or path belongs to. | Count | Construct | Type or path | First | | ---: | --- | --- | --- | -| 17 | a raw pointer to `_` in a variable assigned again while it may point there | `(u32, u32)` | fixtures/reject/src/lib.rs:616:10 | -| 4 | a variant of `_`, which is not supported: either is the same JS string | `std::borrow::Cow` | fixtures/reject/src/lib.rs:331:2 | -| 3 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Gap` | fixtures/reject/src/lib.rs:908:10 | -| 3 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `Mid`, `Outer` | fixtures/reject/src/lib.rs:1355:34 | +| 17 | a raw pointer to `_` in a variable assigned again while it may point there | `(u32, u32)` | fixtures/reject/src/lib.rs:587:10 | +| 4 | a variant of `_`, which is not supported: either is the same JS string | `std::borrow::Cow` | fixtures/reject/src/lib.rs:302:2 | +| 3 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Gap` | fixtures/reject/src/lib.rs:879:10 | +| 3 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `Mid`, `Outer` | fixtures/reject/src/lib.rs:1326:34 | | 3 | unsupported type `_` | `f16` | fixtures/reject/src/lib.rs:7:14 | | 2 | `_` is not supported: its `None` and `Some` would both be `rt.None` | `Option` | fixtures/reject/src/lib.rs:16:15 | | 2 | `_` of `_`, whose `None` is `rt.None`, which is not supported yet | `Iterator::scan`, `Option` | fixtures/reject/src/lib.rs:37:4 | | 2 | `_`, a trait object of another crate's trait, which is not supported yet | `dyn std::iter::Iterator` | fixtures/reject/src/lib.rs:11:16 | -| 2 | `_`, a trait object of the generic trait `_`, which is not supported yet | `dyn Scaled`, `Scaled` | fixtures/reject/src/lib.rs:464:23 | -| 2 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::mem::MaybeUninit`, `Gap` | fixtures/reject/src/lib.rs:922:19 | -| 2 | a raw pointer to `_` in a variable assigned again while it may point there | `[u8; 4]` | fixtures/reject/src/lib.rs:1733:26 | -| 2 | a raw pointer to `_` in a variable assigned again while it may point there | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:696:15 | -| 2 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `[u8; 2]` | fixtures/reject/src/lib.rs:1726:37 | -| 2 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `[u8; 3]` | fixtures/reject/src/lib.rs:1726:15 | -| 2 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Inside` | fixtures/reject/src/lib.rs:1845:20 | -| 2 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `[u8; 4]` | fixtures/reject/src/lib.rs:1733:26 | +| 2 | `_`, a trait object of the generic trait `_`, which is not supported yet | `dyn Scaled`, `Scaled` | fixtures/reject/src/lib.rs:435:23 | +| 2 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::mem::MaybeUninit`, `Gap` | fixtures/reject/src/lib.rs:893:19 | +| 2 | a raw pointer to `_` in a variable assigned again while it may point there | `[u8; 4]` | fixtures/reject/src/lib.rs:1704:26 | +| 2 | a raw pointer to `_` in a variable assigned again while it may point there | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:667:15 | +| 2 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `[u8; 2]` | fixtures/reject/src/lib.rs:1697:37 | +| 2 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `[u8; 3]` | fixtures/reject/src/lib.rs:1697:15 | +| 2 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Inside` | fixtures/reject/src/lib.rs:1816:20 | +| 2 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `[u8; 4]` | fixtures/reject/src/lib.rs:1704:26 | | 2 | an assignment through a reference to `_` | `std::pin::Pin` | fixtures/reject/src/lib.rs:107:2 | -| 2 | comparing pointers to `_`, each a place JS makes of its own | `u32` | fixtures/reject/src/lib.rs:596:2 | +| 2 | comparing pointers to `_`, each a place JS makes of its own | `u32` | fixtures/reject/src/lib.rs:567:2 | | 2 | replacing the value behind a reference to `_` | `std::pin::Pin` | fixtures/reject/src/lib.rs:91:2 | -| 2 | unsupported call to `_` | `::sum` | fixtures/reject/src/lib.rs:434:17 | -| 1 | `Buf::copy_to_bytes` of `_`, a value JS copies, which is not supported | `Blank` | fixtures/reject/src/lib.rs:761:2 | -| 1 | `BufMut::put` of `_` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported | `Counted` | fixtures/reject/src/lib.rs:394:2 | -| 1 | `BufMut::put` of `_` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported | `Counted` | fixtures/reject/src/lib.rs:389:2 | -| 1 | `Bytes::from_owner` of `_`, which would drop with the last clone of what it makes, which is not supported | `std::sync::Arc` | fixtures/reject/src/lib.rs:374:2 | -| 1 | `Extend` of `_` by `_`, whose `_` of `_` is not supported yet | `(std::vec::Vec, Tens)`, `(u8, u8)`, `Tens`, `u8` | fixtures/reject/src/lib.rs:1272:31 | +| 2 | unsupported call to `_` | `::sum` | fixtures/reject/src/lib.rs:405:17 | +| 1 | `Buf::copy_to_bytes` of `_`, a value JS copies, which is not supported | `Blank` | fixtures/reject/src/lib.rs:732:2 | +| 1 | `BufMut::put` of `_` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported | `Counted` | fixtures/reject/src/lib.rs:365:2 | +| 1 | `BufMut::put` of `_` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported | `Counted` | fixtures/reject/src/lib.rs:360:2 | +| 1 | `Bytes::from_owner` of `_`, which would drop with the last clone of what it makes, which is not supported | `std::sync::Arc` | fixtures/reject/src/lib.rs:345:2 | +| 1 | `Extend` of `_` by `_`, whose `_` of `_` is not supported yet | `(std::vec::Vec, Tens)`, `(u8, u8)`, `Tens`, `u8` | fixtures/reject/src/lib.rs:1243:31 | | 1 | `_` is not supported: its `Pending` and `Ready` would both be `rt.OuterPending` | `Poll` | fixtures/reject/src/lib.rs:72:20 | | 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `None` would be `rt.None` as `_` | `Maybe`, `value`, `Option`, `T \| undefined`, `Option` | fixtures/reject/src/lib.rs:31:2 | -| 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `Pending` would be `rt.OuterPending` as `_` | `Waiting`, `poll`, `Poll`, `rt.Poll`, `Poll` | fixtures/reject/src/lib.rs:502:2 | -| 1 | `_` of `_` by `_`, which is not supported yet | `HashMap::contains_key`, `std::collections::HashMap`, `u8` | fixtures/reject/src/lib.rs:253:6 | -| 1 | `_` of `_`, which is not supported yet | `std::any::Any::type_id`, `dyn std::any::Any` | fixtures/reject/src/lib.rs:538:4 | -| 1 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | `Clone::clone_from`, `std::vec::Vec` | fixtures/reject/src/lib.rs:2169:4 | -| 1 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | `slice::clone_from_slice`, `Reused` | fixtures/reject/src/lib.rs:286:4 | +| 1 | `_` is not supported: its field `_` is `_`, typed `_`, whose `Pending` would be `rt.OuterPending` as `_` | `Waiting`, `poll`, `Poll`, `rt.Poll`, `Poll` | fixtures/reject/src/lib.rs:473:2 | +| 1 | `_` of `_` by `_`, which is not supported yet | `HashMap::contains_key`, `std::collections::HashMap`, `u8` | fixtures/reject/src/lib.rs:224:6 | +| 1 | `_` of `_`, which is not supported yet | `std::any::Any::type_id`, `dyn std::any::Any` | fixtures/reject/src/lib.rs:509:4 | +| 1 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | `Clone::clone_from`, `std::vec::Vec` | fixtures/reject/src/lib.rs:2140:4 | +| 1 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | `slice::clone_from_slice`, `Reused` | fixtures/reject/src/lib.rs:257:4 | | 1 | `_` of `_`, whose `clone_from` is its own, which is not supported yet | `slice::fill`, `Reused` | fixtures/reject/src/lib.rs:21:4 | -| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::collections::LinkedList::retain` | fixtures/reject/src/lib.rs:2117:4 | -| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::default::Default::default` | fixtures/reject/src/lib.rs:2119:2 | -| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::iter::once` | fixtures/reject/src/lib.rs:1235:22 | -| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::str::from_utf8_mut` | fixtures/reject/src/lib.rs:1642:20 | -| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::str::get_unchecked_mut` | fixtures/reject/src/lib.rs:1637:13 | -| 1 | `_`, which is not supported yet | `Hasher::write` | fixtures/reject/src/lib.rs:261:9 | -| 1 | `_`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported | `BytesMut::capacity` | fixtures/reject/src/lib.rs:383:6 | -| 1 | `clone_from` of `_`, whose items' `clone_from` is their own, which is not supported yet | `std::collections::LinkedList` | fixtures/reject/src/lib.rs:2118:4 | -| 1 | `collect` of `_`, which sorts by `_`'s own `Ord`, of entries that drop, which is not supported yet | `std::collections::BTreeMap`, `std::cell::Cell` | fixtures/reject/src/lib.rs:955:22 | +| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::collections::LinkedList::retain` | fixtures/reject/src/lib.rs:2088:4 | +| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::default::Default::default` | fixtures/reject/src/lib.rs:2090:2 | +| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::iter::once` | fixtures/reject/src/lib.rs:1206:22 | +| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::str::from_utf8_mut` | fixtures/reject/src/lib.rs:1613:20 | +| 1 | `_` with a mutable reference to a value JS copies, which its mapping would copy | `std::str::get_unchecked_mut` | fixtures/reject/src/lib.rs:1608:13 | +| 1 | `_`, which is not supported yet | `Hasher::write` | fixtures/reject/src/lib.rs:232:9 | +| 1 | `_`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported | `BytesMut::capacity` | fixtures/reject/src/lib.rs:354:6 | +| 1 | `clone_from` of `_`, whose items' `clone_from` is their own, which is not supported yet | `std::collections::LinkedList` | fixtures/reject/src/lib.rs:2089:4 | +| 1 | `collect` of `_`, which sorts by `_`'s own `Ord`, of entries that drop, which is not supported yet | `std::collections::BTreeMap`, `std::cell::Cell` | fixtures/reject/src/lib.rs:926:22 | | 1 | `fmt::Arguments` with a placeholder, or not made in place, written to `_`'s own `fmt::Write`, which is not supported yet: std splits what a placeholder writes into `write_str` calls the runtime does not make | `Sink` | fixtures/reject/src/lib.rs:55:10 | -| 1 | a `collect` in place of `_`, a zip std reads by index, holding values that drop, which is not supported yet | `std::iter::Map` | fixtures/reject/src/lib.rs:209:40 | -| 1 | a `skip` of `_`, a zip std reads by index, of items that drop, which is not supported yet | `std::iter::Zip` | fixtures/reject/src/lib.rs:202:8 | +| 1 | a `collect` in place of `_`, a zip std reads by index, holding values that drop, which is not supported yet | `std::iter::Map` | fixtures/reject/src/lib.rs:180:40 | +| 1 | a `skip` of `_`, a zip std reads by index, of items that drop, which is not supported yet | `std::iter::Zip` | fixtures/reject/src/lib.rs:173:8 | | 1 | a cast from `_` to `_` | `u64`, `f16` | fixtures/reject/src/lib.rs:68:2 | -| 1 | a cast from `_` to `_`, which reads the bytes of one type as another | `*const [u8; 4]`, `*const u8` | fixtures/reject/src/lib.rs:1713:33 | -| 1 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | `[u8; 4]`, `u8` | fixtures/reject/src/lib.rs:1713:17 | -| 1 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | `u32`, `u8` | fixtures/reject/src/lib.rs:555:27 | -| 1 | a coercion of `_` to `_`, a pointer to a slice | `*const [u8; 4]`, `*const [u8]` | fixtures/reject/src/lib.rs:1714:28 | -| 1 | a coercion to `_` | `std::sync::Arc` | fixtures/reject/src/lib.rs:291:2 | -| 1 | a coercion to `_`, which is not supported yet | `&Tail` | fixtures/reject/src/lib.rs:491:30 | -| 1 | a coercion to `_`, which is not supported yet | `std::sync::Weak` | fixtures/reject/src/lib.rs:455:40 | -| 1 | a constant of type `_`, a pointer into memory translation can't name | `&u32` | fixtures/reject/src/lib.rs:778:3 | -| 1 | a dangling pointer to `_`, a value of no bytes made of more than structs and tuples | `Only` | fixtures/reject/src/lib.rs:737:11 | +| 1 | a cast from `_` to `_`, which reads the bytes of one type as another | `*const [u8; 4]`, `*const u8` | fixtures/reject/src/lib.rs:1684:33 | +| 1 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | `[u8; 4]`, `u8` | fixtures/reject/src/lib.rs:1684:17 | +| 1 | a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another | `u32`, `u8` | fixtures/reject/src/lib.rs:526:27 | +| 1 | a coercion of `_` to `_`, a pointer to a slice | `*const [u8; 4]`, `*const [u8]` | fixtures/reject/src/lib.rs:1685:28 | +| 1 | a coercion to `_` | `std::sync::Arc` | fixtures/reject/src/lib.rs:262:2 | +| 1 | a coercion to `_`, which is not supported yet | `&Tail` | fixtures/reject/src/lib.rs:462:30 | +| 1 | a coercion to `_`, which is not supported yet | `std::sync::Weak` | fixtures/reject/src/lib.rs:426:40 | +| 1 | a constant of type `_`, a pointer into memory translation can't name | `&u32` | fixtures/reject/src/lib.rs:749:3 | +| 1 | a dangling pointer to `_`, a value of no bytes made of more than structs and tuples | `Only` | fixtures/reject/src/lib.rs:708:11 | | 1 | a future of `_`, which can be `rt.Pending`, as the future's own `Pending` is | `std::task::Poll` | fixtures/reject/src/lib.rs:77:34 | -| 1 | a mapped guard of `_`, which JS can't write in place | `{closure}` | fixtures/reject/src/lib.rs:2152:10 | -| 1 | a raw pointer to `_` behind a reference, which is the object and not where it is kept | `std::vec::Vec` | fixtures/reject/src/lib.rs:577:10 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u16, u16)`, `Copied` | fixtures/reject/src/lib.rs:1176:31 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u16, u16)`, `Pushed` | fixtures/reject/src/lib.rs:1248:22 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Lane` | fixtures/reject/src/lib.rs:872:19 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Plain` | fixtures/reject/src/lib.rs:826:10 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Span2` | fixtures/reject/src/lib.rs:608:10 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Track` | fixtures/reject/src/lib.rs:852:19 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Window` | fixtures/reject/src/lib.rs:669:2 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:687:15 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `(Dropped, (u8, u8))` | fixtures/reject/src/lib.rs:2263:2 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Cloned; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2247:2 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Greatest; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2281:13 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Touched; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2312:2 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeyReplace`, `(u16, ByKeyReplace)` | fixtures/reject/src/lib.rs:1621:55 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeySet`, `(u16, ByKeySet)` | fixtures/reject/src/lib.rs:1613:51 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeyTake`, `(u16, ByKeyTake)` | fixtures/reject/src/lib.rs:1628:52 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByRefReplace`, `(u16, ByRefReplace)` | fixtures/reject/src/lib.rs:1597:32 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByRefTake`, `(u16, ByRefTake)` | fixtures/reject/src/lib.rs:1605:32 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Aliased` | fixtures/reject/src/lib.rs:1120:29 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByBox` | fixtures/reject/src/lib.rs:1504:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByClosure` | fixtures/reject/src/lib.rs:1519:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByExchanged` | fixtures/reject/src/lib.rs:1565:30 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByInstance` | fixtures/reject/src/lib.rs:1545:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByObject` | fixtures/reject/src/lib.rs:1532:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByRead` | fixtures/reject/src/lib.rs:1455:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByReplace` | fixtures/reject/src/lib.rs:1493:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `BySwap` | fixtures/reject/src/lib.rs:1481:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `BySwapped` | fixtures/reject/src/lib.rs:1554:76 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByWrite` | fixtures/reject/src/lib.rs:1468:35 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Called` | fixtures/reject/src/lib.rs:1086:28 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Escaped` | fixtures/reject/src/lib.rs:1072:43 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Hits` | fixtures/reject/src/lib.rs:720:21 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InArray` | fixtures/reject/src/lib.rs:1302:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InField` | fixtures/reject/src/lib.rs:1318:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InGeneric` | fixtures/reject/src/lib.rs:1322:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InNested` | fixtures/reject/src/lib.rs:1310:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InPayload` | fixtures/reject/src/lib.rs:1314:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InTuple` | fixtures/reject/src/lib.rs:1306:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InWritten` | fixtures/reject/src/lib.rs:1326:9 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Loaded` | fixtures/reject/src/lib.rs:1142:29 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Looped` | fixtures/reject/src/lib.rs:1110:26 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Mapped` | fixtures/reject/src/lib.rs:1187:39 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Onced` | fixtures/reject/src/lib.rs:1233:46 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Repeated` | fixtures/reject/src/lib.rs:1221:18 | -| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Rewritten` | fixtures/reject/src/lib.rs:1130:47 | -| 1 | a raw pointer to `_` in a variable assigned again while it may point there | `Target` | fixtures/reject/src/lib.rs:1669:10 | -| 1 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `(u32, u32)` | fixtures/reject/src/lib.rs:679:10 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InArray`, `[InArray; 2]` | fixtures/reject/src/lib.rs:1337:33 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InTuple`, `(u16, InTuple)` | fixtures/reject/src/lib.rs:1346:33 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InWritten`, `[InWritten; 1]` | fixtures/reject/src/lib.rs:1398:35 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `Parked`, `Parking` | fixtures/reject/src/lib.rs:2137:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Assigned` | fixtures/reject/src/lib.rs:2012:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Closed` | fixtures/reject/src/lib.rs:2078:15 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Deeper` | fixtures/reject/src/lib.rs:2038:22 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Dynamic` | fixtures/reject/src/lib.rs:2062:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Replaced` | fixtures/reject/src/lib.rs:1957:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Swapped` | fixtures/reject/src/lib.rs:1975:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Taken` | fixtures/reject/src/lib.rs:1993:20 | -| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `[std::cell::UnsafeCell; 2]` | fixtures/reject/src/lib.rs:2091:20 | -| 1 | a reference through which a raw pointer may be made into `_` in an element, a payload, or a union field, which is not supported yet | `InPayload` | fixtures/reject/src/lib.rs:1364:11 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Behind` | fixtures/reject/src/lib.rs:1751:22 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Chosen` | fixtures/reject/src/lib.rs:1906:17 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Compared` | fixtures/reject/src/lib.rs:1873:22 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Deep` | fixtures/reject/src/lib.rs:1787:18 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Enclosing` | fixtures/reject/src/lib.rs:1890:22 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Shared` | fixtures/reject/src/lib.rs:1828:20 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Slotted` | fixtures/reject/src/lib.rs:1809:21 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Unboxed` | fixtures/reject/src/lib.rs:1766:16 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Wrapped` | fixtures/reject/src/lib.rs:1934:21 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:1655:18 | -| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `std::option::Option` | fixtures/reject/src/lib.rs:2108:13 | +| 1 | a mapped guard of `_`, which JS can't write in place | `{closure}` | fixtures/reject/src/lib.rs:2123:10 | +| 1 | a raw pointer to `_` behind a reference, which is the object and not where it is kept | `std::vec::Vec` | fixtures/reject/src/lib.rs:548:10 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u16, u16)`, `Copied` | fixtures/reject/src/lib.rs:1147:31 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u16, u16)`, `Pushed` | fixtures/reject/src/lib.rs:1219:22 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Lane` | fixtures/reject/src/lib.rs:843:19 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Plain` | fixtures/reject/src/lib.rs:797:10 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Span2` | fixtures/reject/src/lib.rs:579:10 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Track` | fixtures/reject/src/lib.rs:823:19 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `Window` | fixtures/reject/src/lib.rs:640:2 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u32, u32)`, `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:658:15 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `(Dropped, (u8, u8))` | fixtures/reject/src/lib.rs:2234:2 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Cloned; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2218:2 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Greatest; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2252:13 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `(u8, u8)`, `([Touched; 2], (u8, u8))` | fixtures/reject/src/lib.rs:2283:2 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeyReplace`, `(u16, ByKeyReplace)` | fixtures/reject/src/lib.rs:1592:55 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeySet`, `(u16, ByKeySet)` | fixtures/reject/src/lib.rs:1584:51 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByKeyTake`, `(u16, ByKeyTake)` | fixtures/reject/src/lib.rs:1599:52 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByRefReplace`, `(u16, ByRefReplace)` | fixtures/reject/src/lib.rs:1568:32 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `ByRefTake`, `(u16, ByRefTake)` | fixtures/reject/src/lib.rs:1576:32 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Aliased` | fixtures/reject/src/lib.rs:1091:29 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByBox` | fixtures/reject/src/lib.rs:1475:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByClosure` | fixtures/reject/src/lib.rs:1490:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByExchanged` | fixtures/reject/src/lib.rs:1536:30 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByInstance` | fixtures/reject/src/lib.rs:1516:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByObject` | fixtures/reject/src/lib.rs:1503:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByRead` | fixtures/reject/src/lib.rs:1426:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByReplace` | fixtures/reject/src/lib.rs:1464:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `BySwap` | fixtures/reject/src/lib.rs:1452:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `BySwapped` | fixtures/reject/src/lib.rs:1525:76 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `ByWrite` | fixtures/reject/src/lib.rs:1439:35 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Called` | fixtures/reject/src/lib.rs:1057:28 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Escaped` | fixtures/reject/src/lib.rs:1043:43 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Hits` | fixtures/reject/src/lib.rs:691:21 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InArray` | fixtures/reject/src/lib.rs:1273:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InField` | fixtures/reject/src/lib.rs:1289:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InGeneric` | fixtures/reject/src/lib.rs:1293:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InNested` | fixtures/reject/src/lib.rs:1281:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InPayload` | fixtures/reject/src/lib.rs:1285:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InTuple` | fixtures/reject/src/lib.rs:1277:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `InWritten` | fixtures/reject/src/lib.rs:1297:9 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Loaded` | fixtures/reject/src/lib.rs:1113:29 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Looped` | fixtures/reject/src/lib.rs:1081:26 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Mapped` | fixtures/reject/src/lib.rs:1158:39 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Onced` | fixtures/reject/src/lib.rs:1204:46 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Repeated` | fixtures/reject/src/lib.rs:1192:18 | +| 1 | a raw pointer to `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Rewritten` | fixtures/reject/src/lib.rs:1101:47 | +| 1 | a raw pointer to `_` in a variable assigned again while it may point there | `Target` | fixtures/reject/src/lib.rs:1640:10 | +| 1 | a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet | `(u32, u32)` | fixtures/reject/src/lib.rs:650:10 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InArray`, `[InArray; 2]` | fixtures/reject/src/lib.rs:1308:33 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InTuple`, `(u16, InTuple)` | fixtures/reject/src/lib.rs:1317:33 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `InWritten`, `[InWritten; 1]` | fixtures/reject/src/lib.rs:1369:35 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `Parked`, `Parking` | fixtures/reject/src/lib.rs:2108:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Assigned` | fixtures/reject/src/lib.rs:1983:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Closed` | fixtures/reject/src/lib.rs:2049:15 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Deeper` | fixtures/reject/src/lib.rs:2009:22 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Dynamic` | fixtures/reject/src/lib.rs:2033:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Replaced` | fixtures/reject/src/lib.rs:1928:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Swapped` | fixtures/reject/src/lib.rs:1946:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `Taken` | fixtures/reject/src/lib.rs:1964:20 | +| 1 | a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of | `std::cell::UnsafeCell`, `[std::cell::UnsafeCell; 2]` | fixtures/reject/src/lib.rs:2062:20 | +| 1 | a reference through which a raw pointer may be made into `_` in an element, a payload, or a union field, which is not supported yet | `InPayload` | fixtures/reject/src/lib.rs:1335:11 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Behind` | fixtures/reject/src/lib.rs:1722:22 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Chosen` | fixtures/reject/src/lib.rs:1877:17 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Compared` | fixtures/reject/src/lib.rs:1844:22 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Deep` | fixtures/reject/src/lib.rs:1758:18 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Enclosing` | fixtures/reject/src/lib.rs:1861:22 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Shared` | fixtures/reject/src/lib.rs:1799:20 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Slotted` | fixtures/reject/src/lib.rs:1780:21 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Unboxed` | fixtures/reject/src/lib.rs:1737:16 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `Wrapped` | fixtures/reject/src/lib.rs:1905:21 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `std::cell::UnsafeCell` | fixtures/reject/src/lib.rs:1626:18 | +| 1 | a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there | `std::option::Option` | fixtures/reject/src/lib.rs:2079:13 | | 1 | a scalar constant of type `_` | `f16` | fixtures/reject/src/lib.rs:8:2 | -| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `Reused` | fixtures/reject/src/lib.rs:2164:2 | -| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `std::cell::LazyCell` | fixtures/reject/src/lib.rs:2206:3 | -| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `std::thread::LocalKey` | fixtures/reject/src/lib.rs:2217:2 | -| 1 | a trait object of `_`, which is not supported yet | `[u8; 4]` | fixtures/reject/src/lib.rs:481:26 | -| 1 | an assignment through a reference to `_` | `std::sync::LazyLock` | fixtures/reject/src/lib.rs:2211:2 | +| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `Reused` | fixtures/reject/src/lib.rs:2135:2 | +| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `std::cell::LazyCell` | fixtures/reject/src/lib.rs:2177:3 | +| 1 | a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there | `std::thread::LocalKey` | fixtures/reject/src/lib.rs:2188:2 | +| 1 | a trait object of `_`, which is not supported yet | `[u8; 4]` | fixtures/reject/src/lib.rs:452:26 | +| 1 | an assignment through a reference to `_` | `std::sync::LazyLock` | fixtures/reject/src/lib.rs:2182:2 | | 1 | an assignment through a reference to `_` | `std::sync::MutexGuard` | fixtures/reject/src/lib.rs:83:2 | -| 1 | an iterator of the crate implementing `_`, which is not supported yet | `DoubleEndedIterator` | fixtures/reject/src/lib.rs:145:1 | -| 1 | an iterator of the crate implementing `_`, which is not supported yet | `FusedIterator` | fixtures/reject/src/lib.rs:193:1 | -| 1 | an upcast from `_` to `_`, which is not supported yet | `dyn Keyed`, `dyn std::any::Any` | fixtures/reject/src/lib.rs:532:32 | +| 1 | an upcast from `_` to `_`, which is not supported yet | `dyn Keyed`, `dyn std::any::Any` | fixtures/reject/src/lib.rs:503:32 | | 1 | arithmetic on `_` | `f16` | fixtures/reject/src/lib.rs:8:2 | -| 1 | comparing `_` | `*mut [u8; 4]` | fixtures/reject/src/lib.rs:1712:41 | -| 1 | comparing `_` as a key, which is not supported yet | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:235:75 | -| 1 | comparing pointers to `_` in an atomic, which JS has no address of | `u32` | fixtures/reject/src/lib.rs:777:15 | -| 1 | comparing pointers to `_`, which has no bytes and so no address of its own | `Fused` | fixtures/reject/src/lib.rs:728:70 | -| 1 | const generic types are not supported: `_` | `Block` | fixtures/reject/src/lib.rs:2097:1 | -| 1 | constructing `_` | `std::borrow::Cow` | fixtures/reject/src/lib.rs:349:53 | -| 1 | hashing `_` as a key, which is not supported yet | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:235:75 | -| 1 | hashing `_` by its address, which JS has no counterpart of | `*const [u8; 4]` | fixtures/reject/src/lib.rs:1716:5 | -| 1 | hashing `_` through `_`'s own `Hash::hash_slice`, which is not supported yet | `std::vec::Vec`, `Batched` | fixtures/reject/src/lib.rs:310:16 | +| 1 | comparing `_` | `*mut [u8; 4]` | fixtures/reject/src/lib.rs:1683:41 | +| 1 | comparing `_` as a key, which is not supported yet | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:206:75 | +| 1 | comparing pointers to `_` in an atomic, which JS has no address of | `u32` | fixtures/reject/src/lib.rs:748:15 | +| 1 | comparing pointers to `_`, which has no bytes and so no address of its own | `Bare` | fixtures/reject/src/lib.rs:699:70 | +| 1 | const generic types are not supported: `_` | `Block` | fixtures/reject/src/lib.rs:2068:1 | +| 1 | constructing `_` | `std::borrow::Cow` | fixtures/reject/src/lib.rs:320:53 | +| 1 | hashing `_` as a key, which is not supported yet | `std::collections::BTreeSet` | fixtures/reject/src/lib.rs:206:75 | +| 1 | hashing `_` by its address, which JS has no counterpart of | `*const [u8; 4]` | fixtures/reject/src/lib.rs:1687:5 | +| 1 | hashing `_` through `_`'s own `Hash::hash_slice`, which is not supported yet | `std::vec::Vec`, `Batched` | fixtures/reject/src/lib.rs:281:16 | +| 1 | overriding `_`, which std's adaptors call in place of `next` or beside it | `DoubleEndedIterator::nth_back` | fixtures/reject/src/lib.rs:150:2 | | 1 | overriding `_`, which std's adaptors call in place of `next` or beside it | `Iterator::fold` | fixtures/reject/src/lib.rs:125:2 | -| 1 | overriding `_`, which std's adaptors call in place of `next` or beside it | `Iterator::size_hint` | fixtures/reject/src/lib.rs:173:2 | -| 1 | passing `_`, a closure that owns a value that drops, to `_`, which is not supported yet | `{closure}`, `Entry::or_insert_with` | fixtures/reject/src/lib.rs:319:13 | -| 1 | passing `_`, which drops, to `_`, which is not supported yet | `{closure}`, `String::retain` | fixtures/reject/src/lib.rs:784:4 | -| 1 | passing `_`, which drops, to `_`, which is not supported yet | `{closure}`, `str::contains` | fixtures/reject/src/lib.rs:326:4 | +| 1 | passing `_`, a closure that owns a value that drops, to `_`, which is not supported yet | `{closure}`, `Entry::or_insert_with` | fixtures/reject/src/lib.rs:290:13 | +| 1 | passing `_`, which drops, to `_`, which is not supported yet | `{closure}`, `String::retain` | fixtures/reject/src/lib.rs:755:4 | +| 1 | passing `_`, which drops, to `_`, which is not supported yet | `{closure}`, `str::contains` | fixtures/reject/src/lib.rs:297:4 | | 1 | replacing the value behind a reference to `_` | `std::sync::MutexGuard` | fixtures/reject/src/lib.rs:112:2 | -| 1 | union `_`, whose fields overlap in `_` and `f64`, which JS keeps apart | `Bits`, `u32` | fixtures/reject/src/lib.rs:582:1 | -| 1 | unsupported call to `_` | `::eq` | fixtures/reject/src/lib.rs:538:2 | -| 1 | unsupported call to `_` | `::contains` | fixtures/reject/src/lib.rs:984:32 | -| 1 | unsupported call to `_` | `::eq` | fixtures/reject/src/lib.rs:369:2 | -| 1 | unsupported call to `_` | `::is_sorted` | fixtures/reject/src/lib.rs:766:15 | -| 1 | unsupported call to `_` | `::hash` | fixtures/reject/src/lib.rs:301:10 | -| 1 | unsupported call to `_` | `std::any::TypeId::of` | fixtures/reject/src/lib.rs:538:17 | -| 1 | unsupported call to `_` | `std::borrow::Cow::is_borrowed` | fixtures/reject/src/lib.rs:343:2 | -| 1 | unsupported call to `_` | `std::mem::size_of_val` | fixtures/reject/src/lib.rs:2174:2 | -| 1 | unsupported call to `_` | `std::num::is_ascii_octdigit` | fixtures/reject/src/lib.rs:1277:4 | -| 1 | unsupported call to `_` | `std::ops::Range::contains` | fixtures/reject/src/lib.rs:160:8 | -| 1 | unsupported call to `_` | `std::ops::Range::is_empty` | fixtures/reject/src/lib.rs:989:9 | -| 1 | unsupported call to `_` | `std::ops::RangeTo::contains` | fixtures/reject/src/lib.rs:984:11 | -| 1 | unsupported call to `_` | `std::ptr::addr_eq` | fixtures/reject/src/lib.rs:1712:14 | -| 1 | unsupported call to `_` | `std::ptr::const_ptr::len` | fixtures/reject/src/lib.rs:1717:58 | -| 1 | unsupported call to `_` | `std::ptr::const_ptr::offset` | fixtures/reject/src/lib.rs:1713:73 | -| 1 | unsupported call to `_` | `std::ptr::copy_nonoverlapping` | fixtures/reject/src/lib.rs:1711:3 | -| 1 | unsupported call to `_` | `std::ptr::copy` | fixtures/reject/src/lib.rs:1710:3 | -| 1 | unsupported call to `_` | `std::ptr::mut_ptr::add` | fixtures/reject/src/lib.rs:1713:56 | -| 1 | unsupported call to `_` | `std::std::Layout::new` | fixtures/reject/src/lib.rs:565:15 | -| 1 | unsupported call to `_` | `std::std::alloc` | fixtures/reject/src/lib.rs:567:11 | -| 1 | unsupported call to `_` | `std::std::dealloc` | fixtures/reject/src/lib.rs:570:3 | -| 1 | unsupported call to `_` | `std::str::as_bytes_mut` | fixtures/reject/src/lib.rs:1636:13 | -| 1 | unsupported call to `_` | `std::str::parse` | fixtures/reject/src/lib.rs:439:4 | -| 1 | unsupported type `_` from another crate | `std::net::AddrParseError` | fixtures/reject/src/lib.rs:438:32 | -| 1 | unsupported type `_` from another crate | `std::net::Ipv4Addr` | fixtures/reject/src/lib.rs:438:32 | +| 1 | union `_`, whose fields overlap in `_` and `f64`, which JS keeps apart | `Bits`, `u32` | fixtures/reject/src/lib.rs:553:1 | +| 1 | unsupported call to `_` | `::eq` | fixtures/reject/src/lib.rs:509:2 | +| 1 | unsupported call to `_` | `::contains` | fixtures/reject/src/lib.rs:955:32 | +| 1 | unsupported call to `_` | `::eq` | fixtures/reject/src/lib.rs:340:2 | +| 1 | unsupported call to `_` | `::is_sorted` | fixtures/reject/src/lib.rs:737:15 | +| 1 | unsupported call to `_` | `::hash` | fixtures/reject/src/lib.rs:272:10 | +| 1 | unsupported call to `_` | `std::any::TypeId::of` | fixtures/reject/src/lib.rs:509:17 | +| 1 | unsupported call to `_` | `std::borrow::Cow::is_borrowed` | fixtures/reject/src/lib.rs:314:2 | +| 1 | unsupported call to `_` | `std::mem::size_of_val` | fixtures/reject/src/lib.rs:2145:2 | +| 1 | unsupported call to `_` | `std::num::is_ascii_octdigit` | fixtures/reject/src/lib.rs:1248:4 | +| 1 | unsupported call to `_` | `std::ops::Range::contains` | fixtures/reject/src/lib.rs:164:8 | +| 1 | unsupported call to `_` | `std::ops::Range::is_empty` | fixtures/reject/src/lib.rs:960:9 | +| 1 | unsupported call to `_` | `std::ops::RangeTo::contains` | fixtures/reject/src/lib.rs:955:11 | +| 1 | unsupported call to `_` | `std::ptr::addr_eq` | fixtures/reject/src/lib.rs:1683:14 | +| 1 | unsupported call to `_` | `std::ptr::const_ptr::len` | fixtures/reject/src/lib.rs:1688:58 | +| 1 | unsupported call to `_` | `std::ptr::const_ptr::offset` | fixtures/reject/src/lib.rs:1684:73 | +| 1 | unsupported call to `_` | `std::ptr::copy_nonoverlapping` | fixtures/reject/src/lib.rs:1682:3 | +| 1 | unsupported call to `_` | `std::ptr::copy` | fixtures/reject/src/lib.rs:1681:3 | +| 1 | unsupported call to `_` | `std::ptr::mut_ptr::add` | fixtures/reject/src/lib.rs:1684:56 | +| 1 | unsupported call to `_` | `std::std::Layout::new` | fixtures/reject/src/lib.rs:536:15 | +| 1 | unsupported call to `_` | `std::std::alloc` | fixtures/reject/src/lib.rs:538:11 | +| 1 | unsupported call to `_` | `std::std::dealloc` | fixtures/reject/src/lib.rs:541:3 | +| 1 | unsupported call to `_` | `std::str::as_bytes_mut` | fixtures/reject/src/lib.rs:1607:13 | +| 1 | unsupported call to `_` | `std::str::parse` | fixtures/reject/src/lib.rs:410:4 | +| 1 | unsupported type `_` from another crate | `std::net::AddrParseError` | fixtures/reject/src/lib.rs:409:32 | +| 1 | unsupported type `_` from another crate | `std::net::Ipv4Addr` | fixtures/reject/src/lib.rs:409:32 | ## Spans
a raw pointer to `_` in `_`, which the crate may put another object in place of (49) -- fixtures/reject/src/lib.rs:608:10: a raw pointer to `(u32, u32)` in `Span2`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:669:2: a raw pointer to `(u32, u32)` in `Window`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:687:15: a raw pointer to `(u32, u32)` in `std::cell::UnsafeCell<(u32, u32)>`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:720:21: a raw pointer to `std::cell::UnsafeCell` in `Hits`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:826:10: a raw pointer to `(u32, u32)` in `Plain`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:852:19: a raw pointer to `(u32, u32)` in `Track`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:872:19: a raw pointer to `(u32, u32)` in `Lane`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:908:10: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:909:10: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:910:58: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:922:19: a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:923:19: a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1072:43: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Escaped`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1086:28: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Called`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1110:26: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Looped`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1120:29: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Aliased`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1130:47: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Rewritten`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1142:29: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Loaded`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1176:31: a raw pointer to `(u16, u16)` in `Copied`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1187:39: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Mapped`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1221:18: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Repeated`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1233:46: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Onced`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1248:22: a raw pointer to `(u16, u16)` in `Pushed`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1302:9: a raw pointer to `std::cell::UnsafeCell` in `InArray`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1306:9: a raw pointer to `std::cell::UnsafeCell` in `InTuple`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1310:9: a raw pointer to `std::cell::UnsafeCell` in `InNested`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1314:9: a raw pointer to `std::cell::UnsafeCell` in `InPayload`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1318:9: a raw pointer to `std::cell::UnsafeCell` in `InField`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1322:9: a raw pointer to `std::cell::UnsafeCell` in `InGeneric`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1326:9: a raw pointer to `std::cell::UnsafeCell` in `InWritten`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1455:35: a raw pointer to `std::cell::UnsafeCell` in `ByRead`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1468:35: a raw pointer to `std::cell::UnsafeCell` in `ByWrite`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1481:35: a raw pointer to `std::cell::UnsafeCell` in `BySwap`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1493:35: a raw pointer to `std::cell::UnsafeCell` in `ByReplace`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1504:35: a raw pointer to `std::cell::UnsafeCell` in `ByBox`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1519:35: a raw pointer to `std::cell::UnsafeCell` in `ByClosure`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1532:35: a raw pointer to `std::cell::UnsafeCell` in `ByObject`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1545:35: a raw pointer to `std::cell::UnsafeCell` in `ByInstance`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1554:76: a raw pointer to `std::cell::UnsafeCell` in `BySwapped`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1565:30: a raw pointer to `std::cell::UnsafeCell` in `ByExchanged`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1597:32: a raw pointer to `ByRefReplace` in `(u16, ByRefReplace)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1605:32: a raw pointer to `ByRefTake` in `(u16, ByRefTake)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1613:51: a raw pointer to `ByKeySet` in `(u16, ByKeySet)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1621:55: a raw pointer to `ByKeyReplace` in `(u16, ByKeyReplace)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1628:52: a raw pointer to `ByKeyTake` in `(u16, ByKeyTake)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2247:2: a raw pointer to `(u8, u8)` in `([Cloned; 2], (u8, u8))`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2263:2: a raw pointer to `(u8, u8)` in `(Dropped, (u8, u8))`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2281:13: a raw pointer to `(u8, u8)` in `([Greatest; 2], (u8, u8))`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2312:2: a raw pointer to `(u8, u8)` in `([Touched; 2], (u8, u8))`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:579:10: a raw pointer to `(u32, u32)` in `Span2`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:640:2: a raw pointer to `(u32, u32)` in `Window`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:658:15: a raw pointer to `(u32, u32)` in `std::cell::UnsafeCell<(u32, u32)>`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:691:21: a raw pointer to `std::cell::UnsafeCell` in `Hits`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:797:10: a raw pointer to `(u32, u32)` in `Plain`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:823:19: a raw pointer to `(u32, u32)` in `Track`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:843:19: a raw pointer to `(u32, u32)` in `Lane`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:879:10: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:880:10: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:881:58: a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:893:19: a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:894:19: a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1043:43: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Escaped`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1057:28: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Called`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1081:26: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Looped`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1091:29: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Aliased`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1101:47: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Rewritten`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1113:29: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Loaded`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1147:31: a raw pointer to `(u16, u16)` in `Copied`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1158:39: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Mapped`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1192:18: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Repeated`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1204:46: a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Onced`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1219:22: a raw pointer to `(u16, u16)` in `Pushed`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1273:9: a raw pointer to `std::cell::UnsafeCell` in `InArray`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1277:9: a raw pointer to `std::cell::UnsafeCell` in `InTuple`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1281:9: a raw pointer to `std::cell::UnsafeCell` in `InNested`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1285:9: a raw pointer to `std::cell::UnsafeCell` in `InPayload`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1289:9: a raw pointer to `std::cell::UnsafeCell` in `InField`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1293:9: a raw pointer to `std::cell::UnsafeCell` in `InGeneric`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1297:9: a raw pointer to `std::cell::UnsafeCell` in `InWritten`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1426:35: a raw pointer to `std::cell::UnsafeCell` in `ByRead`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1439:35: a raw pointer to `std::cell::UnsafeCell` in `ByWrite`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1452:35: a raw pointer to `std::cell::UnsafeCell` in `BySwap`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1464:35: a raw pointer to `std::cell::UnsafeCell` in `ByReplace`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1475:35: a raw pointer to `std::cell::UnsafeCell` in `ByBox`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1490:35: a raw pointer to `std::cell::UnsafeCell` in `ByClosure`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1503:35: a raw pointer to `std::cell::UnsafeCell` in `ByObject`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1516:35: a raw pointer to `std::cell::UnsafeCell` in `ByInstance`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1525:76: a raw pointer to `std::cell::UnsafeCell` in `BySwapped`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1536:30: a raw pointer to `std::cell::UnsafeCell` in `ByExchanged`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1568:32: a raw pointer to `ByRefReplace` in `(u16, ByRefReplace)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1576:32: a raw pointer to `ByRefTake` in `(u16, ByRefTake)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1584:51: a raw pointer to `ByKeySet` in `(u16, ByKeySet)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1592:55: a raw pointer to `ByKeyReplace` in `(u16, ByKeyReplace)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1599:52: a raw pointer to `ByKeyTake` in `(u16, ByKeyTake)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2218:2: a raw pointer to `(u8, u8)` in `([Cloned; 2], (u8, u8))`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2234:2: a raw pointer to `(u8, u8)` in `(Dropped, (u8, u8))`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2252:13: a raw pointer to `(u8, u8)` in `([Greatest; 2], (u8, u8))`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2283:2: a raw pointer to `(u8, u8)` in `([Touched; 2], (u8, u8))`, which the crate may put another object in place of
unsupported call to `_` (25) -- fixtures/reject/src/lib.rs:160:8: unsupported call to `std::ops::Range::::contains::` -- fixtures/reject/src/lib.rs:301:10: unsupported call to `::hash::` -- fixtures/reject/src/lib.rs:343:2: unsupported call to `std::borrow::Cow::<'_, [u8]>::is_borrowed` -- fixtures/reject/src/lib.rs:369:2: unsupported call to ` as std::cmp::PartialEq>::eq` -- fixtures/reject/src/lib.rs:434:17: unsupported call to ` as std::iter::Iterator>::sum::` -- fixtures/reject/src/lib.rs:434:38: unsupported call to ` as std::iter::Iterator>::sum::` -- fixtures/reject/src/lib.rs:439:4: unsupported call to `core::str::::parse::` -- fixtures/reject/src/lib.rs:538:2: unsupported call to `::eq` -- fixtures/reject/src/lib.rs:538:17: unsupported call to `std::any::TypeId::of::` -- fixtures/reject/src/lib.rs:565:15: unsupported call to `std::alloc::Layout::new::` -- fixtures/reject/src/lib.rs:567:11: unsupported call to `std::alloc::alloc` -- fixtures/reject/src/lib.rs:570:3: unsupported call to `std::alloc::dealloc` -- fixtures/reject/src/lib.rs:766:15: unsupported call to ` as std::iter::Iterator>::is_sorted` -- fixtures/reject/src/lib.rs:984:11: unsupported call to `std::ops::RangeTo::::contains::` -- fixtures/reject/src/lib.rs:984:32: unsupported call to ` as std::ops::RangeBounds>::contains::` -- fixtures/reject/src/lib.rs:989:9: unsupported call to `std::ops::Range::<&mut u8>::is_empty` -- fixtures/reject/src/lib.rs:1277:4: unsupported call to `core::num::::is_ascii_octdigit` -- fixtures/reject/src/lib.rs:1636:13: unsupported call to `core::str::::as_bytes_mut` -- fixtures/reject/src/lib.rs:1710:3: unsupported call to `std::ptr::copy::<[u8; 4]>` -- fixtures/reject/src/lib.rs:1711:3: unsupported call to `std::ptr::copy_nonoverlapping::<[u8; 4]>` -- fixtures/reject/src/lib.rs:1712:14: unsupported call to `std::ptr::addr_eq::<[u8; 4], [u8; 4]>` -- fixtures/reject/src/lib.rs:1713:56: unsupported call to `std::ptr::mut_ptr::::add` -- fixtures/reject/src/lib.rs:1713:73: unsupported call to `std::ptr::const_ptr::::offset` -- fixtures/reject/src/lib.rs:1717:58: unsupported call to `std::ptr::const_ptr::::len` -- fixtures/reject/src/lib.rs:2174:2: unsupported call to `std::mem::size_of_val::` +- fixtures/reject/src/lib.rs:164:8: unsupported call to `std::ops::Range::::contains::` +- fixtures/reject/src/lib.rs:272:10: unsupported call to `::hash::` +- fixtures/reject/src/lib.rs:314:2: unsupported call to `std::borrow::Cow::<'_, [u8]>::is_borrowed` +- fixtures/reject/src/lib.rs:340:2: unsupported call to ` as std::cmp::PartialEq>::eq` +- fixtures/reject/src/lib.rs:405:17: unsupported call to ` as std::iter::Iterator>::sum::` +- fixtures/reject/src/lib.rs:405:38: unsupported call to ` as std::iter::Iterator>::sum::` +- fixtures/reject/src/lib.rs:410:4: unsupported call to `core::str::::parse::` +- fixtures/reject/src/lib.rs:509:2: unsupported call to `::eq` +- fixtures/reject/src/lib.rs:509:17: unsupported call to `std::any::TypeId::of::` +- fixtures/reject/src/lib.rs:536:15: unsupported call to `std::alloc::Layout::new::` +- fixtures/reject/src/lib.rs:538:11: unsupported call to `std::alloc::alloc` +- fixtures/reject/src/lib.rs:541:3: unsupported call to `std::alloc::dealloc` +- fixtures/reject/src/lib.rs:737:15: unsupported call to ` as std::iter::Iterator>::is_sorted` +- fixtures/reject/src/lib.rs:955:11: unsupported call to `std::ops::RangeTo::::contains::` +- fixtures/reject/src/lib.rs:955:32: unsupported call to ` as std::ops::RangeBounds>::contains::` +- fixtures/reject/src/lib.rs:960:9: unsupported call to `std::ops::Range::<&mut u8>::is_empty` +- fixtures/reject/src/lib.rs:1248:4: unsupported call to `core::num::::is_ascii_octdigit` +- fixtures/reject/src/lib.rs:1607:13: unsupported call to `core::str::::as_bytes_mut` +- fixtures/reject/src/lib.rs:1681:3: unsupported call to `std::ptr::copy::<[u8; 4]>` +- fixtures/reject/src/lib.rs:1682:3: unsupported call to `std::ptr::copy_nonoverlapping::<[u8; 4]>` +- fixtures/reject/src/lib.rs:1683:14: unsupported call to `std::ptr::addr_eq::<[u8; 4], [u8; 4]>` +- fixtures/reject/src/lib.rs:1684:56: unsupported call to `std::ptr::mut_ptr::::add` +- fixtures/reject/src/lib.rs:1684:73: unsupported call to `std::ptr::const_ptr::::offset` +- fixtures/reject/src/lib.rs:1688:58: unsupported call to `std::ptr::const_ptr::::len` +- fixtures/reject/src/lib.rs:2145:2: unsupported call to `std::mem::size_of_val::`
a raw pointer to `_` in a variable assigned again while it may point there (22) -- fixtures/reject/src/lib.rs:616:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:624:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:633:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:641:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:650:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:658:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:696:15: a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:709:15: a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1001:26: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1014:22: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1024:12: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1033:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1043:17: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1048:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1669:10: a raw pointer to `Target` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1682:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1697:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1733:26: a raw pointer to `[u8; 4]` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:1734:10: a raw pointer to `[u8; 4]` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:2180:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:2188:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there -- fixtures/reject/src/lib.rs:2196:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:587:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:595:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:604:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:612:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:621:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:629:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:667:15: a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:680:15: a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:972:26: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:985:22: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:995:12: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1004:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1014:17: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1019:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1640:10: a raw pointer to `Target` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1653:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1668:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1704:26: a raw pointer to `[u8; 4]` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:1705:10: a raw pointer to `[u8; 4]` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:2151:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:2159:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there +- fixtures/reject/src/lib.rs:2167:10: a raw pointer to `(u32, u32)` in a variable assigned again while it may point there
a reference through which a raw pointer may be made into `_` in `_`, which the crate may put another object in place of (15) -- fixtures/reject/src/lib.rs:1337:33: a reference through which a raw pointer may be made into `InArray` in `[InArray; 2]`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1346:33: a reference through which a raw pointer may be made into `InTuple` in `(u16, InTuple)`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1355:34: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1376:33: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1389:35: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1398:35: a reference through which a raw pointer may be made into `InWritten` in `[InWritten; 1]`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1957:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Replaced`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1975:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Swapped`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:1993:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Taken`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2012:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Assigned`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2038:22: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Deeper`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2062:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Dynamic`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2078:15: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Closed`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2091:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `[std::cell::UnsafeCell; 2]`, which the crate may put another object in place of -- fixtures/reject/src/lib.rs:2137:20: a reference through which a raw pointer may be made into `Parked` in `Parking`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1308:33: a reference through which a raw pointer may be made into `InArray` in `[InArray; 2]`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1317:33: a reference through which a raw pointer may be made into `InTuple` in `(u16, InTuple)`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1326:34: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1347:33: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1360:35: a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1369:35: a reference through which a raw pointer may be made into `InWritten` in `[InWritten; 1]`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1928:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Replaced`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1946:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Swapped`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1964:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Taken`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:1983:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Assigned`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2009:22: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Deeper`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2033:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Dynamic`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2049:15: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Closed`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2062:20: a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `[std::cell::UnsafeCell; 2]`, which the crate may put another object in place of +- fixtures/reject/src/lib.rs:2108:20: a reference through which a raw pointer may be made into `Parked` in `Parking`, which the crate may put another object in place of
a reference to `_`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there (15) -- fixtures/reject/src/lib.rs:1655:18: a reference to `std::cell::UnsafeCell`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1733:26: a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1751:22: a reference to `Behind`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1766:16: a reference to `Unboxed`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1787:18: a reference to `Deep`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1809:21: a reference to `Slotted`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1828:20: a reference to `Shared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1845:20: a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1858:26: a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1873:22: a reference to `Compared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1890:22: a reference to `Enclosing`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1906:17: a reference to `Chosen`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1919:19: a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:1934:21: a reference to `Wrapped>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there -- fixtures/reject/src/lib.rs:2108:13: a reference to `std::option::Option>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1626:18: a reference to `std::cell::UnsafeCell`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1704:26: a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1722:22: a reference to `Behind`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1737:16: a reference to `Unboxed`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1758:18: a reference to `Deep`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1780:21: a reference to `Slotted`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1799:20: a reference to `Shared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1816:20: a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1829:26: a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1844:22: a reference to `Compared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1861:22: a reference to `Enclosing`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1877:17: a reference to `Chosen`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1890:19: a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:1905:21: a reference to `Wrapped>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there +- fixtures/reject/src/lib.rs:2079:13: a reference to `std::option::Option>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there
`_` with a mutable reference to a value JS copies, which its mapping would copy (5) -- fixtures/reject/src/lib.rs:1235:22: `std::iter::once` with a mutable reference to a value JS copies, which its mapping would copy -- fixtures/reject/src/lib.rs:1637:13: `core::str::::get_unchecked_mut` with a mutable reference to a value JS copies, which its mapping would copy -- fixtures/reject/src/lib.rs:1642:20: `std::str::from_utf8_mut` with a mutable reference to a value JS copies, which its mapping would copy -- fixtures/reject/src/lib.rs:2117:4: `std::collections::LinkedList::::retain` with a mutable reference to a value JS copies, which its mapping would copy -- fixtures/reject/src/lib.rs:2119:2: `std::default::Default::default` with a mutable reference to a value JS copies, which its mapping would copy +- fixtures/reject/src/lib.rs:1206:22: `std::iter::once` with a mutable reference to a value JS copies, which its mapping would copy +- fixtures/reject/src/lib.rs:1608:13: `core::str::::get_unchecked_mut` with a mutable reference to a value JS copies, which its mapping would copy +- fixtures/reject/src/lib.rs:1613:20: `std::str::from_utf8_mut` with a mutable reference to a value JS copies, which its mapping would copy +- fixtures/reject/src/lib.rs:2088:4: `std::collections::LinkedList::::retain` with a mutable reference to a value JS copies, which its mapping would copy +- fixtures/reject/src/lib.rs:2090:2: `std::default::Default::default` with a mutable reference to a value JS copies, which its mapping would copy
a raw pointer to `_` in an element, a payload, or a union field, which is not supported yet (5) -- fixtures/reject/src/lib.rs:679:10: a raw pointer to `(u32, u32)` in an element, a payload, or a union field, which is not supported yet -- fixtures/reject/src/lib.rs:1726:15: a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet -- fixtures/reject/src/lib.rs:1726:18: a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet -- fixtures/reject/src/lib.rs:1726:37: a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet -- fixtures/reject/src/lib.rs:1726:44: a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:650:10: a raw pointer to `(u32, u32)` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:1697:15: a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:1697:18: a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:1697:37: a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:1697:44: a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet
a variant of `_`, which is not supported: either is the same JS string (4) -- fixtures/reject/src/lib.rs:331:2: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string -- fixtures/reject/src/lib.rs:332:30: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string -- fixtures/reject/src/lib.rs:333:27: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string -- fixtures/reject/src/lib.rs:338:2: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string +- fixtures/reject/src/lib.rs:302:2: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string +- fixtures/reject/src/lib.rs:303:30: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string +- fixtures/reject/src/lib.rs:304:27: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string +- fixtures/reject/src/lib.rs:309:2: a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string
@@ -626,32 +622,32 @@ The type or module each refused type or path belongs to. - fixtures/reject/src/lib.rs:83:2: an assignment through a reference to `std::sync::MutexGuard<'_, u8>` - fixtures/reject/src/lib.rs:107:2: an assignment through a reference to `std::pin::Pin>>` -- fixtures/reject/src/lib.rs:214:2: an assignment through a reference to `std::pin::Pin<&mut Noisy>` -- fixtures/reject/src/lib.rs:2211:2: an assignment through a reference to `std::sync::LazyLock` +- fixtures/reject/src/lib.rs:185:2: an assignment through a reference to `std::pin::Pin<&mut Noisy>` +- fixtures/reject/src/lib.rs:2182:2: an assignment through a reference to `std::sync::LazyLock`
`_` of `_`, whose `clone_from` is its own, which is not supported yet (3) - fixtures/reject/src/lib.rs:21:4: `slice::fill` of `Reused`, whose `clone_from` is its own, which is not supported yet -- fixtures/reject/src/lib.rs:286:4: `slice::clone_from_slice` of `Reused`, whose `clone_from` is its own, which is not supported yet -- fixtures/reject/src/lib.rs:2169:4: `Clone::clone_from` of `std::vec::Vec`, whose `clone_from` is its own, which is not supported yet +- fixtures/reject/src/lib.rs:257:4: `slice::clone_from_slice` of `Reused`, whose `clone_from` is its own, which is not supported yet +- fixtures/reject/src/lib.rs:2140:4: `Clone::clone_from` of `std::vec::Vec`, whose `clone_from` is its own, which is not supported yet
a copy of a closure that changes what it captured (3) -- fixtures/reject/src/lib.rs:224:14: a copy of a closure that changes what it captured -- fixtures/reject/src/lib.rs:514:14: a copy of a closure that changes what it captured -- fixtures/reject/src/lib.rs:515:14: a copy of a closure that changes what it captured +- fixtures/reject/src/lib.rs:195:14: a copy of a closure that changes what it captured +- fixtures/reject/src/lib.rs:485:14: a copy of a closure that changes what it captured +- fixtures/reject/src/lib.rs:486:14: a copy of a closure that changes what it captured
a slice or a cell of a mutable reference to `_` that names no place, which a whole write would replace only there (3) -- fixtures/reject/src/lib.rs:2164:2: a slice or a cell of a mutable reference to `Reused` that names no place, which a whole write would replace only there -- fixtures/reject/src/lib.rs:2206:3: a slice or a cell of a mutable reference to `std::cell::LazyCell` that names no place, which a whole write would replace only there -- fixtures/reject/src/lib.rs:2217:2: a slice or a cell of a mutable reference to `std::thread::LocalKey` that names no place, which a whole write would replace only there +- fixtures/reject/src/lib.rs:2135:2: a slice or a cell of a mutable reference to `Reused` that names no place, which a whole write would replace only there +- fixtures/reject/src/lib.rs:2177:3: a slice or a cell of a mutable reference to `std::cell::LazyCell` that names no place, which a whole write would replace only there +- fixtures/reject/src/lib.rs:2188:2: a slice or a cell of a mutable reference to `std::thread::LocalKey` that names no place, which a whole write would replace only there
@@ -681,7 +677,7 @@ The type or module each refused type or path belongs to.
`_` of `_`, whose `None` is `rt.None`, which is not supported yet (2) - fixtures/reject/src/lib.rs:37:4: `Iterator::scan` of `Option>`, whose `None` is `rt.None`, which is not supported yet -- fixtures/reject/src/lib.rs:230:11: `Iterator::scan` of `Option<()>`, whose `None` is `rt.None`, which is not supported yet +- fixtures/reject/src/lib.rs:201:11: `Iterator::scan` of `Option<()>`, whose `None` is `rt.None`, which is not supported yet
@@ -694,94 +690,87 @@ The type or module each refused type or path belongs to.
`_`, a trait object of the generic trait `_`, which is not supported yet (2) -- fixtures/reject/src/lib.rs:464:23: `dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet -- fixtures/reject/src/lib.rs:465:4: `dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet +- fixtures/reject/src/lib.rs:435:23: `dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet +- fixtures/reject/src/lib.rs:436:4: `dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet
a cast from a pointer to `_` to one to `_`, which reads the bytes of one type as another (2) -- fixtures/reject/src/lib.rs:555:27: a cast from a pointer to `u32` to one to `u8`, which reads the bytes of one type as another -- fixtures/reject/src/lib.rs:1713:17: a cast from a pointer to `[u8; 4]` to one to `u8`, which reads the bytes of one type as another +- fixtures/reject/src/lib.rs:526:27: a cast from a pointer to `u32` to one to `u8`, which reads the bytes of one type as another +- fixtures/reject/src/lib.rs:1684:17: a cast from a pointer to `[u8; 4]` to one to `u8`, which reads the bytes of one type as another
a coercion to `_`, which is not supported yet (2) -- fixtures/reject/src/lib.rs:455:40: a coercion to `std::sync::Weak`, which is not supported yet -- fixtures/reject/src/lib.rs:491:30: a coercion to `&Tail`, which is not supported yet +- fixtures/reject/src/lib.rs:426:40: a coercion to `std::sync::Weak`, which is not supported yet +- fixtures/reject/src/lib.rs:462:30: a coercion to `&Tail`, which is not supported yet
a raw pointer to a place of `()`, which has no address of its own (2) -- fixtures/reject/src/lib.rs:728:15: a raw pointer to a place of `()`, which has no address of its own -- fixtures/reject/src/lib.rs:728:29: a raw pointer to a place of `()`, which has no address of its own - -
- -
an iterator of the crate implementing `_`, which is not supported yet (2) - -- fixtures/reject/src/lib.rs:145:1: an iterator of the crate implementing `DoubleEndedIterator`, which is not supported yet -- fixtures/reject/src/lib.rs:193:1: an iterator of the crate implementing `FusedIterator`, which is not supported yet +- fixtures/reject/src/lib.rs:699:15: a raw pointer to a place of `()`, which has no address of its own +- fixtures/reject/src/lib.rs:699:29: a raw pointer to a place of `()`, which has no address of its own
comparing pointers to `_`, each a place JS makes of its own (2) -- fixtures/reject/src/lib.rs:596:2: comparing pointers to `u32`, each a place JS makes of its own -- fixtures/reject/src/lib.rs:2145:2: comparing pointers to `u32`, each a place JS makes of its own +- fixtures/reject/src/lib.rs:567:2: comparing pointers to `u32`, each a place JS makes of its own +- fixtures/reject/src/lib.rs:2116:2: comparing pointers to `u32`, each a place JS makes of its own
overriding `_`, which std's adaptors call in place of `next` or beside it (2) - fixtures/reject/src/lib.rs:125:2: overriding `Iterator::fold`, which std's adaptors call in place of `next` or beside it -- fixtures/reject/src/lib.rs:173:2: overriding `Iterator::size_hint`, which std's adaptors call in place of `next` or beside it +- fixtures/reject/src/lib.rs:150:2: overriding `DoubleEndedIterator::nth_back`, which std's adaptors call in place of `next` or beside it
passing `_`, which drops, to `_`, which is not supported yet (2) -- fixtures/reject/src/lib.rs:326:4: passing `{closure@fixtures/reject/src/lib.rs:326:13: 326:27}`, which drops, to `str::contains`, which is not supported yet -- fixtures/reject/src/lib.rs:784:4: passing `{closure@fixtures/reject/src/lib.rs:784:11: 784:19}`, which drops, to `String::retain`, which is not supported yet +- fixtures/reject/src/lib.rs:297:4: passing `{closure@fixtures/reject/src/lib.rs:297:13: 297:27}`, which drops, to `str::contains`, which is not supported yet +- fixtures/reject/src/lib.rs:755:4: passing `{closure@fixtures/reject/src/lib.rs:755:11: 755:19}`, which drops, to `String::retain`, which is not supported yet
unsupported type `_` from another crate (2) -- fixtures/reject/src/lib.rs:438:32: unsupported type `std::net::AddrParseError` from another crate -- fixtures/reject/src/lib.rs:438:32: unsupported type `std::net::Ipv4Addr` from another crate +- fixtures/reject/src/lib.rs:409:32: unsupported type `std::net::AddrParseError` from another crate +- fixtures/reject/src/lib.rs:409:32: unsupported type `std::net::Ipv4Addr` from another crate
`Buf::copy_to_bytes` of `_`, a value JS copies, which is not supported (1) -- fixtures/reject/src/lib.rs:761:2: `Buf::copy_to_bytes` of `Blank`, a value JS copies, which is not supported +- fixtures/reject/src/lib.rs:732:2: `Buf::copy_to_bytes` of `Blank`, a value JS copies, which is not supported
`BufMut::put` of `_` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported (1) -- fixtures/reject/src/lib.rs:394:2: `BufMut::put` of `Counted` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported +- fixtures/reject/src/lib.rs:365:2: `BufMut::put` of `Counted` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported
`BufMut::put` of `_` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported (1) -- fixtures/reject/src/lib.rs:389:2: `BufMut::put` of `Counted` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported +- fixtures/reject/src/lib.rs:360:2: `BufMut::put` of `Counted` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported
`Bytes::from_owner` of `_`, which would drop with the last clone of what it makes, which is not supported (1) -- fixtures/reject/src/lib.rs:374:2: `Bytes::from_owner` of `std::sync::Arc<[u8]>`, which would drop with the last clone of what it makes, which is not supported +- fixtures/reject/src/lib.rs:345:2: `Bytes::from_owner` of `std::sync::Arc<[u8]>`, which would drop with the last clone of what it makes, which is not supported
`Extend` of `_` by `_`, whose `_` of `_` is not supported yet (1) -- fixtures/reject/src/lib.rs:1272:31: `Extend` of `(std::vec::Vec, Tens)` by `(u8, u8)`, whose `Tens` of `u8` is not supported yet +- fixtures/reject/src/lib.rs:1243:31: `Extend` of `(std::vec::Vec, Tens)` by `(u8, u8)`, whose `Tens` of `u8` is not supported yet
@@ -805,43 +794,43 @@ The type or module each refused type or path belongs to.
`_` is not supported: its field `_` is `_`, typed `_`, whose `Pending` would be `rt.OuterPending` as `_` (1) -- fixtures/reject/src/lib.rs:502:2: `Waiting>` is not supported: its field `poll` is `Poll`, typed `rt.Poll`, whose `Pending` would be `rt.OuterPending` as `Poll>` +- fixtures/reject/src/lib.rs:473:2: `Waiting>` is not supported: its field `poll` is `Poll`, typed `rt.Poll`, whose `Pending` would be `rt.OuterPending` as `Poll>`
`_` of `_` by `_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:253:6: `HashMap::contains_key` of `std::collections::HashMap` by `u8`, which is not supported yet +- fixtures/reject/src/lib.rs:224:6: `HashMap::contains_key` of `std::collections::HashMap` by `u8`, which is not supported yet
`_` of `_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:538:4: `std::any::Any::type_id` of `dyn std::any::Any`, which is not supported yet +- fixtures/reject/src/lib.rs:509:4: `std::any::Any::type_id` of `dyn std::any::Any`, which is not supported yet
`_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:261:9: `Hasher::write`, which is not supported yet +- fixtures/reject/src/lib.rs:232:9: `Hasher::write`, which is not supported yet
`_`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported (1) -- fixtures/reject/src/lib.rs:383:6: `BytesMut::capacity`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported +- fixtures/reject/src/lib.rs:354:6: `BytesMut::capacity`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported
`clone_from` of `_`, whose items' `clone_from` is their own, which is not supported yet (1) -- fixtures/reject/src/lib.rs:2118:4: `clone_from` of `std::collections::LinkedList`, whose items' `clone_from` is their own, which is not supported yet +- fixtures/reject/src/lib.rs:2089:4: `clone_from` of `std::collections::LinkedList`, whose items' `clone_from` is their own, which is not supported yet
`collect` of `_`, which sorts by `_`'s own `Ord`, of entries that drop, which is not supported yet (1) -- fixtures/reject/src/lib.rs:955:22: `collect` of `std::collections::BTreeMap, Noisy>`, which sorts by `std::cell::Cell`'s own `Ord`, of entries that drop, which is not supported yet +- fixtures/reject/src/lib.rs:926:22: `collect` of `std::collections::BTreeMap, Noisy>`, which sorts by `std::cell::Cell`'s own `Ord`, of entries that drop, which is not supported yet
@@ -853,13 +842,13 @@ The type or module each refused type or path belongs to.
a `collect` in place of `_`, a zip std reads by index, holding values that drop, which is not supported yet (1) -- fixtures/reject/src/lib.rs:209:40: a `collect` in place of `std::iter::Map, {closure@fixtures/reject/src/lib.rs:208:32: 208:40}>, std::ops::Range>, {closure@fixtures/reject/src/lib.rs:209:24: 209:32}>`, a zip std reads by index, holding values that drop, which is not supported yet +- fixtures/reject/src/lib.rs:180:40: a `collect` in place of `std::iter::Map, {closure@fixtures/reject/src/lib.rs:179:32: 179:40}>, std::ops::Range>, {closure@fixtures/reject/src/lib.rs:180:24: 180:32}>`, a zip std reads by index, holding values that drop, which is not supported yet
a `skip` of `_`, a zip std reads by index, of items that drop, which is not supported yet (1) -- fixtures/reject/src/lib.rs:202:8: a `skip` of `std::iter::Zip, {closure@fixtures/reject/src/lib.rs:201:27: 201:31}>, std::iter::Map, {closure@fixtures/reject/src/lib.rs:201:59: 201:63}>>`, a zip std reads by index, of items that drop, which is not supported yet +- fixtures/reject/src/lib.rs:173:8: a `skip` of `std::iter::Zip, {closure@fixtures/reject/src/lib.rs:172:27: 172:31}>, std::iter::Map, {closure@fixtures/reject/src/lib.rs:172:59: 172:63}>>`, a zip std reads by index, of items that drop, which is not supported yet
@@ -871,31 +860,31 @@ The type or module each refused type or path belongs to.
a cast from `_` to `_`, which reads the bytes of one type as another (1) -- fixtures/reject/src/lib.rs:1713:33: a cast from `*const [u8; 4]` to `*const u8`, which reads the bytes of one type as another +- fixtures/reject/src/lib.rs:1684:33: a cast from `*const [u8; 4]` to `*const u8`, which reads the bytes of one type as another
a coercion of `_` to `_`, a pointer to a slice (1) -- fixtures/reject/src/lib.rs:1714:28: a coercion of `*const [u8; 4]` to `*const [u8]`, a pointer to a slice +- fixtures/reject/src/lib.rs:1685:28: a coercion of `*const [u8; 4]` to `*const [u8]`, a pointer to a slice
a coercion to `_` (1) -- fixtures/reject/src/lib.rs:291:2: a coercion to `std::sync::Arc<[u8]>` +- fixtures/reject/src/lib.rs:262:2: a coercion to `std::sync::Arc<[u8]>`
a constant of type `_`, a pointer into memory translation can't name (1) -- fixtures/reject/src/lib.rs:778:3: a constant of type `&u32`, a pointer into memory translation can't name +- fixtures/reject/src/lib.rs:749:3: a constant of type `&u32`, a pointer into memory translation can't name
a dangling pointer to `_`, a value of no bytes made of more than structs and tuples (1) -- fixtures/reject/src/lib.rs:737:11: a dangling pointer to `Only`, a value of no bytes made of more than structs and tuples +- fixtures/reject/src/lib.rs:708:11: a dangling pointer to `Only`, a value of no bytes made of more than structs and tuples
@@ -907,13 +896,13 @@ The type or module each refused type or path belongs to.
a mapped guard of `_`, which JS can't write in place (1) -- fixtures/reject/src/lib.rs:2152:10: a mapped guard of `{closure@fixtures/reject/src/lib.rs:2151:38: 2151:50}`, which JS can't write in place +- fixtures/reject/src/lib.rs:2123:10: a mapped guard of `{closure@fixtures/reject/src/lib.rs:2122:38: 2122:50}`, which JS can't write in place
a mutable reference into a `Result`'s payload, passed on or kept (1) -- fixtures/reject/src/lib.rs:362:12: a mutable reference into a `Result`'s payload, passed on or kept +- fixtures/reject/src/lib.rs:333:12: a mutable reference into a `Result`'s payload, passed on or kept
@@ -925,7 +914,7 @@ The type or module each refused type or path belongs to.
a pointer's address, which JS has no counterpart of (1) -- fixtures/reject/src/lib.rs:560:17: a pointer's address, which JS has no counterpart of +- fixtures/reject/src/lib.rs:531:17: a pointer's address, which JS has no counterpart of
@@ -937,13 +926,13 @@ The type or module each refused type or path belongs to.
a raw pointer to `_` behind a reference, which is the object and not where it is kept (1) -- fixtures/reject/src/lib.rs:577:10: a raw pointer to `std::vec::Vec` behind a reference, which is the object and not where it is kept +- fixtures/reject/src/lib.rs:548:10: a raw pointer to `std::vec::Vec` behind a reference, which is the object and not where it is kept
a reference through which a raw pointer may be made into `_` in an element, a payload, or a union field, which is not supported yet (1) -- fixtures/reject/src/lib.rs:1364:11: a reference through which a raw pointer may be made into `InPayload` in an element, a payload, or a union field, which is not supported yet +- fixtures/reject/src/lib.rs:1335:11: a reference through which a raw pointer may be made into `InPayload` in an element, a payload, or a union field, which is not supported yet
@@ -955,19 +944,19 @@ The type or module each refused type or path belongs to.
a slice of one byte's place, which a byte slice can view only in an array of bytes (1) -- fixtures/reject/src/lib.rs:2158:2: a slice of one byte's place, which a byte slice can view only in an array of bytes +- fixtures/reject/src/lib.rs:2129:2: a slice of one byte's place, which a byte slice can view only in an array of bytes
a trait object of `_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:481:26: a trait object of `[u8; 4]`, which is not supported yet +- fixtures/reject/src/lib.rs:452:26: a trait object of `[u8; 4]`, which is not supported yet
an upcast from `_` to `_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:532:32: an upcast from `dyn Keyed` to `dyn std::any::Any`, which is not supported yet +- fixtures/reject/src/lib.rs:503:32: an upcast from `dyn Keyed` to `dyn std::any::Any`, which is not supported yet
@@ -979,66 +968,66 @@ The type or module each refused type or path belongs to.
comparing `_` (1) -- fixtures/reject/src/lib.rs:1712:41: comparing `*mut [u8; 4]` +- fixtures/reject/src/lib.rs:1683:41: comparing `*mut [u8; 4]`
comparing `_` as a key, which is not supported yet (1) -- fixtures/reject/src/lib.rs:235:75: comparing `std::collections::BTreeSet` as a key, which is not supported yet +- fixtures/reject/src/lib.rs:206:75: comparing `std::collections::BTreeSet` as a key, which is not supported yet
comparing pointers to `_` in an atomic, which JS has no address of (1) -- fixtures/reject/src/lib.rs:777:15: comparing pointers to `u32` in an atomic, which JS has no address of +- fixtures/reject/src/lib.rs:748:15: comparing pointers to `u32` in an atomic, which JS has no address of
comparing pointers to `_`, which has no bytes and so no address of its own (1) -- fixtures/reject/src/lib.rs:728:70: comparing pointers to `Fused`, which has no bytes and so no address of its own +- fixtures/reject/src/lib.rs:699:70: comparing pointers to `Bare`, which has no bytes and so no address of its own
const generic types are not supported: `_` (1) -- fixtures/reject/src/lib.rs:2097:1: const generic types are not supported: `Block` +- fixtures/reject/src/lib.rs:2068:1: const generic types are not supported: `Block`
constructing `_` (1) -- fixtures/reject/src/lib.rs:349:53: constructing `std::borrow::Cow<'_, std::sync::Arc>` +- fixtures/reject/src/lib.rs:320:53: constructing `std::borrow::Cow<'_, std::sync::Arc>`
hashing `_` as a key, which is not supported yet (1) -- fixtures/reject/src/lib.rs:235:75: hashing `std::collections::BTreeSet` as a key, which is not supported yet +- fixtures/reject/src/lib.rs:206:75: hashing `std::collections::BTreeSet` as a key, which is not supported yet
hashing `_` by its address, which JS has no counterpart of (1) -- fixtures/reject/src/lib.rs:1716:5: hashing `*const [u8; 4]` by its address, which JS has no counterpart of +- fixtures/reject/src/lib.rs:1687:5: hashing `*const [u8; 4]` by its address, which JS has no counterpart of
hashing `_` through `_`'s own `Hash::hash_slice`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:310:16: hashing `std::vec::Vec` through `Batched`'s own `Hash::hash_slice`, which is not supported yet +- fixtures/reject/src/lib.rs:281:16: hashing `std::vec::Vec` through `Batched`'s own `Hash::hash_slice`, which is not supported yet
passing `_`, a closure that owns a value that drops, to `_`, which is not supported yet (1) -- fixtures/reject/src/lib.rs:319:13: passing `{closure@fixtures/reject/src/lib.rs:319:28: 319:35}`, a closure that owns a value that drops, to `Entry::or_insert_with`, which is not supported yet +- fixtures/reject/src/lib.rs:290:13: passing `{closure@fixtures/reject/src/lib.rs:290:28: 290:35}`, a closure that owns a value that drops, to `Entry::or_insert_with`, which is not supported yet
union `_`, whose fields overlap in `_` and `f64`, which JS keeps apart (1) -- fixtures/reject/src/lib.rs:582:1: union `Bits`, whose fields overlap in `u32` and `f64`, which JS keeps apart +- fixtures/reject/src/lib.rs:553:1: union `Bits`, whose fields overlap in `u32` and `f64`, which JS keeps apart
diff --git a/ts/fixtures/reject/expected.txt b/ts/fixtures/reject/expected.txt index 1b991db4d..5b16acbfe 100644 --- a/ts/fixtures/reject/expected.txt +++ b/ts/fixtures/reject/expected.txt @@ -24,208 +24,206 @@ replacing the value behind a reference to `std::sync::MutexGuard<'_, u8>` at fix replacing the value behind a reference to `std::pin::Pin fn(&'a mut std::task::Context<'b>) -> std::task::Poll>>>` at fixtures/reject/src/lib.rs:91:2 an assignment through a reference to `std::pin::Pin>>` at fixtures/reject/src/lib.rs:107:2 replacing the value behind a reference to `std::pin::Pin>` at fixtures/reject/src/lib.rs:99:2 -unsupported call to `std::ops::Range::::contains::` at fixtures/reject/src/lib.rs:160:8 -unsupported call to `std::ops::RangeTo::::contains::` at fixtures/reject/src/lib.rs:984:11 -unsupported call to ` as std::ops::RangeBounds>::contains::` at fixtures/reject/src/lib.rs:984:32 -unsupported call to `std::ops::Range::<&mut u8>::is_empty` at fixtures/reject/src/lib.rs:989:9 -a `skip` of `std::iter::Zip, {closure@fixtures/reject/src/lib.rs:201:27: 201:31}>, std::iter::Map, {closure@fixtures/reject/src/lib.rs:201:59: 201:63}>>`, a zip std reads by index, of items that drop, which is not supported yet at fixtures/reject/src/lib.rs:202:8 -a `collect` in place of `std::iter::Map, {closure@fixtures/reject/src/lib.rs:208:32: 208:40}>, std::ops::Range>, {closure@fixtures/reject/src/lib.rs:209:24: 209:32}>`, a zip std reads by index, holding values that drop, which is not supported yet at fixtures/reject/src/lib.rs:209:40 -an assignment through a reference to `std::pin::Pin<&mut Noisy>` at fixtures/reject/src/lib.rs:214:2 -a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:224:14 -`Iterator::scan` of `Option<()>`, whose `None` is `rt.None`, which is not supported yet at fixtures/reject/src/lib.rs:230:11 -hashing `std::collections::BTreeSet` as a key, which is not supported yet at fixtures/reject/src/lib.rs:235:75 -comparing `std::collections::BTreeSet` as a key, which is not supported yet at fixtures/reject/src/lib.rs:235:75 -`HashMap::contains_key` of `std::collections::HashMap` by `u8`, which is not supported yet at fixtures/reject/src/lib.rs:253:6 -`slice::clone_from_slice` of `Reused`, whose `clone_from` is its own, which is not supported yet at fixtures/reject/src/lib.rs:286:4 -a coercion to `std::sync::Arc<[u8]>` at fixtures/reject/src/lib.rs:291:2 -a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:331:2 -a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:333:27 -a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:332:30 -a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:338:2 -unsupported call to `std::borrow::Cow::<'_, [u8]>::is_borrowed` at fixtures/reject/src/lib.rs:343:2 -constructing `std::borrow::Cow<'_, std::sync::Arc>` at fixtures/reject/src/lib.rs:349:53 -hashing `std::vec::Vec` through `Batched`'s own `Hash::hash_slice`, which is not supported yet at fixtures/reject/src/lib.rs:310:16 -passing `{closure@fixtures/reject/src/lib.rs:319:28: 319:35}`, a closure that owns a value that drops, to `Entry::or_insert_with`, which is not supported yet at fixtures/reject/src/lib.rs:319:13 -passing `{closure@fixtures/reject/src/lib.rs:326:13: 326:27}`, which drops, to `str::contains`, which is not supported yet at fixtures/reject/src/lib.rs:326:4 -unsupported call to ` as std::iter::Iterator>::sum::` at fixtures/reject/src/lib.rs:434:17 -unsupported call to ` as std::iter::Iterator>::sum::` at fixtures/reject/src/lib.rs:434:38 -a mutable reference into a `Result`'s payload, passed on or kept at fixtures/reject/src/lib.rs:362:12 -unsupported call to ` as std::cmp::PartialEq>::eq` at fixtures/reject/src/lib.rs:369:2 -`Bytes::from_owner` of `std::sync::Arc<[u8]>`, which would drop with the last clone of what it makes, which is not supported at fixtures/reject/src/lib.rs:374:2 -`BytesMut::capacity`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:383:6 -`BufMut::put` of `Counted` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:389:2 -`BufMut::put` of `Counted` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:394:2 -unsupported call to `core::str::::parse::` at fixtures/reject/src/lib.rs:439:4 -unsupported type `std::net::Ipv4Addr` from another crate at fixtures/reject/src/lib.rs:438:32 -unsupported type `std::net::AddrParseError` from another crate at fixtures/reject/src/lib.rs:438:32 -a coercion to `std::sync::Weak`, which is not supported yet at fixtures/reject/src/lib.rs:455:40 -`dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet at fixtures/reject/src/lib.rs:464:23 -`dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet at fixtures/reject/src/lib.rs:465:4 -a trait object of `[u8; 4]`, which is not supported yet at fixtures/reject/src/lib.rs:481:26 -a coercion to `&Tail`, which is not supported yet at fixtures/reject/src/lib.rs:491:30 -`Waiting>` is not supported: its field `poll` is `Poll`, typed `rt.Poll`, whose `Pending` would be `rt.OuterPending` as `Poll>` at fixtures/reject/src/lib.rs:502:2 -a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:514:14 -a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:515:14 -an upcast from `dyn Keyed` to `dyn std::any::Any`, which is not supported yet at fixtures/reject/src/lib.rs:532:32 -`std::any::Any::type_id` of `dyn std::any::Any`, which is not supported yet at fixtures/reject/src/lib.rs:538:4 -unsupported call to `std::any::TypeId::of::` at fixtures/reject/src/lib.rs:538:17 -unsupported call to `::eq` at fixtures/reject/src/lib.rs:538:2 -a cast from a pointer to `u32` to one to `u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:555:27 -a pointer's address, which JS has no counterpart of at fixtures/reject/src/lib.rs:560:17 -unsupported call to `std::alloc::Layout::new::` at fixtures/reject/src/lib.rs:565:15 -unsupported call to `std::alloc::alloc` at fixtures/reject/src/lib.rs:567:11 -unsupported call to `std::alloc::dealloc` at fixtures/reject/src/lib.rs:570:3 -a raw pointer to `std::vec::Vec` behind a reference, which is the object and not where it is kept at fixtures/reject/src/lib.rs:577:10 -union `Bits`, whose fields overlap in `u32` and `f64`, which JS keeps apart at fixtures/reject/src/lib.rs:588:10 -comparing pointers to `u32`, each a place JS makes of its own at fixtures/reject/src/lib.rs:596:2 -comparing pointers to `u32`, each a place JS makes of its own at fixtures/reject/src/lib.rs:2145:2 -a raw pointer to `(u32, u32)` in `Span2`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:608:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:616:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:624:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:633:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:641:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:650:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:658:10 -a reference to `std::cell::UnsafeCell`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1655:18 -a raw pointer to `Target` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1669:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1682:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1697:10 -a reference to `Behind`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1751:22 -a reference to `Unboxed`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1766:16 -a reference to `Deep`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1787:18 -a reference to `Slotted`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1809:21 -a reference to `Shared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1828:20 -a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1845:20 -a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1858:26 -a reference to `Wrapped>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1934:21 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Replaced`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1957:20 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Swapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1975:20 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Taken`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1993:20 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Assigned`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2012:20 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Deeper`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2038:22 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Dynamic`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2062:20 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Closed`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2078:15 -a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `[std::cell::UnsafeCell; 2]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2091:20 -a reference to `Compared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1873:22 -a reference to `Enclosing`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1890:22 -a reference to `Chosen`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1906:17 -a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1919:19 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1001:26 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1014:22 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1024:12 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1033:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1043:17 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1048:10 -a raw pointer to `(u32, u32)` in `Window`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:669:2 -a raw pointer to `(u32, u32)` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:679:10 -a raw pointer to `(u32, u32)` in `std::cell::UnsafeCell<(u32, u32)>`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:687:15 -a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:696:15 -a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:709:15 -a raw pointer to `std::cell::UnsafeCell` in `Hits`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:720:21 -a raw pointer to a place of `()`, which has no address of its own at fixtures/reject/src/lib.rs:728:15 -a raw pointer to a place of `()`, which has no address of its own at fixtures/reject/src/lib.rs:728:29 -comparing pointers to `Fused`, which has no bytes and so no address of its own at fixtures/reject/src/lib.rs:728:70 -a dangling pointer to `Only`, a value of no bytes made of more than structs and tuples at fixtures/reject/src/lib.rs:737:11 -`Buf::copy_to_bytes` of `Blank`, a value JS copies, which is not supported at fixtures/reject/src/lib.rs:761:2 -unsupported call to ` as std::iter::Iterator>::is_sorted` at fixtures/reject/src/lib.rs:766:15 -comparing pointers to `u32` in an atomic, which JS has no address of at fixtures/reject/src/lib.rs:777:15 -a constant of type `&u32`, a pointer into memory translation can't name at fixtures/reject/src/lib.rs:778:3 -passing `{closure@fixtures/reject/src/lib.rs:784:11: 784:19}`, which drops, to `String::retain`, which is not supported yet at fixtures/reject/src/lib.rs:784:4 -a raw pointer to `(u32, u32)` in `Plain`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:826:10 -a raw pointer to `(u32, u32)` in `Track`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:852:19 -a raw pointer to `(u32, u32)` in `Lane`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:872:19 -a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:908:10 -a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:909:10 -a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:910:58 -a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:922:19 -a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:923:19 -`collect` of `std::collections::BTreeMap, Noisy>`, which sorts by `std::cell::Cell`'s own `Ord`, of entries that drop, which is not supported yet at fixtures/reject/src/lib.rs:955:22 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Looped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1110:26 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Aliased`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1120:29 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Rewritten`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1130:47 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Loaded`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1142:29 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Mapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1187:39 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Repeated`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1221:18 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Onced`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1233:46 -`std::iter::once` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1235:22 -a raw pointer to `(u16, u16)` in `Pushed`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1248:22 -`Extend` of `(std::vec::Vec, Tens)` by `(u8, u8)`, whose `Tens` of `u8` is not supported yet at fixtures/reject/src/lib.rs:1272:31 -unsupported call to `core::num::::is_ascii_octdigit` at fixtures/reject/src/lib.rs:1277:4 -a reference through which a raw pointer may be made into `InArray` in `[InArray; 2]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1337:33 -a reference through which a raw pointer may be made into `InTuple` in `(u16, InTuple)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1346:33 -a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1355:34 -a reference through which a raw pointer may be made into `InPayload` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1364:11 -a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1376:33 -a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1389:35 -a reference through which a raw pointer may be made into `InWritten` in `[InWritten; 1]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1398:35 -a raw pointer to `std::cell::UnsafeCell` in `ByRead`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1455:35 -a raw pointer to `std::cell::UnsafeCell` in `ByWrite`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1468:35 -a raw pointer to `std::cell::UnsafeCell` in `BySwap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1481:35 -a raw pointer to `std::cell::UnsafeCell` in `ByReplace`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1493:35 -a raw pointer to `std::cell::UnsafeCell` in `ByBox`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1504:35 -a raw pointer to `std::cell::UnsafeCell` in `ByClosure`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1519:35 -a raw pointer to `std::cell::UnsafeCell` in `ByObject`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1532:35 -a raw pointer to `std::cell::UnsafeCell` in `ByInstance`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1545:35 -a raw pointer to `std::cell::UnsafeCell` in `BySwapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1554:76 -a raw pointer to `std::cell::UnsafeCell` in `ByExchanged`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1565:30 -a raw pointer to `ByRefReplace` in `(u16, ByRefReplace)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1597:32 -a raw pointer to `ByRefTake` in `(u16, ByRefTake)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1605:32 -a raw pointer to `ByKeySet` in `(u16, ByKeySet)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1613:51 -a raw pointer to `ByKeyReplace` in `(u16, ByKeyReplace)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1621:55 -a raw pointer to `ByKeyTake` in `(u16, ByKeyTake)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1628:52 -unsupported call to `core::str::::as_bytes_mut` at fixtures/reject/src/lib.rs:1636:13 -`core::str::::get_unchecked_mut` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1637:13 -`std::str::from_utf8_mut` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1642:20 -unsupported call to `std::ptr::copy::<[u8; 4]>` at fixtures/reject/src/lib.rs:1710:3 -unsupported call to `std::ptr::copy_nonoverlapping::<[u8; 4]>` at fixtures/reject/src/lib.rs:1711:3 -unsupported call to `std::ptr::addr_eq::<[u8; 4], [u8; 4]>` at fixtures/reject/src/lib.rs:1712:14 -comparing `*mut [u8; 4]` at fixtures/reject/src/lib.rs:1712:41 -a cast from a pointer to `[u8; 4]` to one to `u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:1713:17 -a cast from `*const [u8; 4]` to `*const u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:1713:33 -unsupported call to `std::ptr::mut_ptr::::add` at fixtures/reject/src/lib.rs:1713:56 -unsupported call to `std::ptr::const_ptr::::offset` at fixtures/reject/src/lib.rs:1713:73 -a coercion of `*const [u8; 4]` to `*const [u8]`, a pointer to a slice at fixtures/reject/src/lib.rs:1714:28 -hashing `*const [u8; 4]` by its address, which JS has no counterpart of at fixtures/reject/src/lib.rs:1716:5 -unsupported call to `std::ptr::const_ptr::::len` at fixtures/reject/src/lib.rs:1717:58 -a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1726:15 -a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1726:18 -a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1726:37 -a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1726:44 -a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1733:26 -a raw pointer to `[u8; 4]` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1733:26 -a raw pointer to `[u8; 4]` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1734:10 -const generic types are not supported: `Block` at fixtures/reject/src/lib.rs:2101:21 -`std::collections::LinkedList::::retain` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:2117:4 -`clone_from` of `std::collections::LinkedList`, whose items' `clone_from` is their own, which is not supported yet at fixtures/reject/src/lib.rs:2118:4 -`std::default::Default::default` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:2119:2 -a mapped guard of `{closure@fixtures/reject/src/lib.rs:2151:38: 2151:50}`, which JS can't write in place at fixtures/reject/src/lib.rs:2152:10 -a slice of one byte's place, which a byte slice can view only in an array of bytes at fixtures/reject/src/lib.rs:2158:2 -a slice or a cell of a mutable reference to `Reused` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2164:2 -`Clone::clone_from` of `std::vec::Vec`, whose `clone_from` is its own, which is not supported yet at fixtures/reject/src/lib.rs:2169:4 -unsupported call to `std::mem::size_of_val::` at fixtures/reject/src/lib.rs:2174:2 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2180:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2188:10 -a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2196:10 -a slice or a cell of a mutable reference to `std::cell::LazyCell` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2206:3 -an assignment through a reference to `std::sync::LazyLock` at fixtures/reject/src/lib.rs:2211:2 -a slice or a cell of a mutable reference to `std::thread::LocalKey` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2217:2 +unsupported call to `std::ops::Range::::contains::` at fixtures/reject/src/lib.rs:164:8 +unsupported call to `std::ops::RangeTo::::contains::` at fixtures/reject/src/lib.rs:955:11 +unsupported call to ` as std::ops::RangeBounds>::contains::` at fixtures/reject/src/lib.rs:955:32 +unsupported call to `std::ops::Range::<&mut u8>::is_empty` at fixtures/reject/src/lib.rs:960:9 +a `skip` of `std::iter::Zip, {closure@fixtures/reject/src/lib.rs:172:27: 172:31}>, std::iter::Map, {closure@fixtures/reject/src/lib.rs:172:59: 172:63}>>`, a zip std reads by index, of items that drop, which is not supported yet at fixtures/reject/src/lib.rs:173:8 +a `collect` in place of `std::iter::Map, {closure@fixtures/reject/src/lib.rs:179:32: 179:40}>, std::ops::Range>, {closure@fixtures/reject/src/lib.rs:180:24: 180:32}>`, a zip std reads by index, holding values that drop, which is not supported yet at fixtures/reject/src/lib.rs:180:40 +an assignment through a reference to `std::pin::Pin<&mut Noisy>` at fixtures/reject/src/lib.rs:185:2 +a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:195:14 +`Iterator::scan` of `Option<()>`, whose `None` is `rt.None`, which is not supported yet at fixtures/reject/src/lib.rs:201:11 +hashing `std::collections::BTreeSet` as a key, which is not supported yet at fixtures/reject/src/lib.rs:206:75 +comparing `std::collections::BTreeSet` as a key, which is not supported yet at fixtures/reject/src/lib.rs:206:75 +`HashMap::contains_key` of `std::collections::HashMap` by `u8`, which is not supported yet at fixtures/reject/src/lib.rs:224:6 +`slice::clone_from_slice` of `Reused`, whose `clone_from` is its own, which is not supported yet at fixtures/reject/src/lib.rs:257:4 +a coercion to `std::sync::Arc<[u8]>` at fixtures/reject/src/lib.rs:262:2 +a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:302:2 +a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:304:27 +a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:303:30 +a variant of `std::borrow::Cow<'_, str>`, which is not supported: either is the same JS string at fixtures/reject/src/lib.rs:309:2 +unsupported call to `std::borrow::Cow::<'_, [u8]>::is_borrowed` at fixtures/reject/src/lib.rs:314:2 +constructing `std::borrow::Cow<'_, std::sync::Arc>` at fixtures/reject/src/lib.rs:320:53 +hashing `std::vec::Vec` through `Batched`'s own `Hash::hash_slice`, which is not supported yet at fixtures/reject/src/lib.rs:281:16 +passing `{closure@fixtures/reject/src/lib.rs:290:28: 290:35}`, a closure that owns a value that drops, to `Entry::or_insert_with`, which is not supported yet at fixtures/reject/src/lib.rs:290:13 +passing `{closure@fixtures/reject/src/lib.rs:297:13: 297:27}`, which drops, to `str::contains`, which is not supported yet at fixtures/reject/src/lib.rs:297:4 +unsupported call to ` as std::iter::Iterator>::sum::` at fixtures/reject/src/lib.rs:405:17 +unsupported call to ` as std::iter::Iterator>::sum::` at fixtures/reject/src/lib.rs:405:38 +a mutable reference into a `Result`'s payload, passed on or kept at fixtures/reject/src/lib.rs:333:12 +unsupported call to ` as std::cmp::PartialEq>::eq` at fixtures/reject/src/lib.rs:340:2 +`Bytes::from_owner` of `std::sync::Arc<[u8]>`, which would drop with the last clone of what it makes, which is not supported at fixtures/reject/src/lib.rs:345:2 +`BytesMut::capacity`, which reads a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:354:6 +`BufMut::put` of `Counted` into a `BytesMut`, which picks the methods it calls by a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:360:2 +`BufMut::put` of `Counted` into a `BytesMut`, which advances it by the room left in a capacity that depends on whether the other handles of its storage dropped, which is not supported at fixtures/reject/src/lib.rs:365:2 +unsupported call to `core::str::::parse::` at fixtures/reject/src/lib.rs:410:4 +unsupported type `std::net::Ipv4Addr` from another crate at fixtures/reject/src/lib.rs:409:32 +unsupported type `std::net::AddrParseError` from another crate at fixtures/reject/src/lib.rs:409:32 +a coercion to `std::sync::Weak`, which is not supported yet at fixtures/reject/src/lib.rs:426:40 +`dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet at fixtures/reject/src/lib.rs:435:23 +`dyn Scaled`, a trait object of the generic trait `Scaled`, which is not supported yet at fixtures/reject/src/lib.rs:436:4 +a trait object of `[u8; 4]`, which is not supported yet at fixtures/reject/src/lib.rs:452:26 +a coercion to `&Tail`, which is not supported yet at fixtures/reject/src/lib.rs:462:30 +`Waiting>` is not supported: its field `poll` is `Poll`, typed `rt.Poll`, whose `Pending` would be `rt.OuterPending` as `Poll>` at fixtures/reject/src/lib.rs:473:2 +a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:485:14 +a copy of a closure that changes what it captured at fixtures/reject/src/lib.rs:486:14 +an upcast from `dyn Keyed` to `dyn std::any::Any`, which is not supported yet at fixtures/reject/src/lib.rs:503:32 +`std::any::Any::type_id` of `dyn std::any::Any`, which is not supported yet at fixtures/reject/src/lib.rs:509:4 +unsupported call to `std::any::TypeId::of::` at fixtures/reject/src/lib.rs:509:17 +unsupported call to `::eq` at fixtures/reject/src/lib.rs:509:2 +a cast from a pointer to `u32` to one to `u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:526:27 +a pointer's address, which JS has no counterpart of at fixtures/reject/src/lib.rs:531:17 +unsupported call to `std::alloc::Layout::new::` at fixtures/reject/src/lib.rs:536:15 +unsupported call to `std::alloc::alloc` at fixtures/reject/src/lib.rs:538:11 +unsupported call to `std::alloc::dealloc` at fixtures/reject/src/lib.rs:541:3 +a raw pointer to `std::vec::Vec` behind a reference, which is the object and not where it is kept at fixtures/reject/src/lib.rs:548:10 +union `Bits`, whose fields overlap in `u32` and `f64`, which JS keeps apart at fixtures/reject/src/lib.rs:559:10 +comparing pointers to `u32`, each a place JS makes of its own at fixtures/reject/src/lib.rs:567:2 +comparing pointers to `u32`, each a place JS makes of its own at fixtures/reject/src/lib.rs:2116:2 +a raw pointer to `(u32, u32)` in `Span2`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:579:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:587:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:595:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:604:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:612:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:621:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:629:10 +a reference to `std::cell::UnsafeCell`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1626:18 +a raw pointer to `Target` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1640:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1653:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1668:10 +a reference to `Behind`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1722:22 +a reference to `Unboxed`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1737:16 +a reference to `Deep`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1758:18 +a reference to `Slotted`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1780:21 +a reference to `Shared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1799:20 +a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1816:20 +a reference to `Inside`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1829:26 +a reference to `Wrapped>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1905:21 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Replaced`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1928:20 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Swapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1946:20 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Taken`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1964:20 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Assigned`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1983:20 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Deeper`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2009:22 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Dynamic`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2033:20 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `Closed`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2049:15 +a reference through which a raw pointer may be made into `std::cell::UnsafeCell` in `[std::cell::UnsafeCell; 2]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2062:20 +a reference to `Compared`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1844:22 +a reference to `Enclosing`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1861:22 +a reference to `Chosen`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1877:17 +a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1890:19 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:972:26 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:985:22 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:995:12 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1004:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1014:17 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1019:10 +a raw pointer to `(u32, u32)` in `Window`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:640:2 +a raw pointer to `(u32, u32)` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:650:10 +a raw pointer to `(u32, u32)` in `std::cell::UnsafeCell<(u32, u32)>`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:658:15 +a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:667:15 +a raw pointer to `std::cell::UnsafeCell` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:680:15 +a raw pointer to `std::cell::UnsafeCell` in `Hits`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:691:21 +a raw pointer to a place of `()`, which has no address of its own at fixtures/reject/src/lib.rs:699:15 +a raw pointer to a place of `()`, which has no address of its own at fixtures/reject/src/lib.rs:699:29 +comparing pointers to `Bare`, which has no bytes and so no address of its own at fixtures/reject/src/lib.rs:699:70 +a dangling pointer to `Only`, a value of no bytes made of more than structs and tuples at fixtures/reject/src/lib.rs:708:11 +`Buf::copy_to_bytes` of `Blank`, a value JS copies, which is not supported at fixtures/reject/src/lib.rs:732:2 +unsupported call to ` as std::iter::Iterator>::is_sorted` at fixtures/reject/src/lib.rs:737:15 +comparing pointers to `u32` in an atomic, which JS has no address of at fixtures/reject/src/lib.rs:748:15 +a constant of type `&u32`, a pointer into memory translation can't name at fixtures/reject/src/lib.rs:749:3 +passing `{closure@fixtures/reject/src/lib.rs:755:11: 755:19}`, which drops, to `String::retain`, which is not supported yet at fixtures/reject/src/lib.rs:755:4 +a raw pointer to `(u32, u32)` in `Plain`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:797:10 +a raw pointer to `(u32, u32)` in `Track`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:823:19 +a raw pointer to `(u32, u32)` in `Lane`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:843:19 +a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:879:10 +a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:880:10 +a raw pointer to `(u32, u32)` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:881:58 +a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:893:19 +a raw pointer to `std::mem::MaybeUninit<(u32, u32)>` in `Gap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:894:19 +`collect` of `std::collections::BTreeMap, Noisy>`, which sorts by `std::cell::Cell`'s own `Ord`, of entries that drop, which is not supported yet at fixtures/reject/src/lib.rs:926:22 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Looped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1081:26 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Aliased`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1091:29 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Rewritten`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1101:47 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Loaded`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1113:29 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Mapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1158:39 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Repeated`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1192:18 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Onced`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1204:46 +`std::iter::once` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1206:22 +a raw pointer to `(u16, u16)` in `Pushed`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1219:22 +`Extend` of `(std::vec::Vec, Tens)` by `(u8, u8)`, whose `Tens` of `u8` is not supported yet at fixtures/reject/src/lib.rs:1243:31 +unsupported call to `core::num::::is_ascii_octdigit` at fixtures/reject/src/lib.rs:1248:4 +a reference through which a raw pointer may be made into `InArray` in `[InArray; 2]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1308:33 +a reference through which a raw pointer may be made into `InTuple` in `(u16, InTuple)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1317:33 +a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1326:34 +a reference through which a raw pointer may be made into `InPayload` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1335:11 +a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1347:33 +a reference through which a raw pointer may be made into `Mid` in `Outer`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1360:35 +a reference through which a raw pointer may be made into `InWritten` in `[InWritten; 1]`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1369:35 +a raw pointer to `std::cell::UnsafeCell` in `ByRead`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1426:35 +a raw pointer to `std::cell::UnsafeCell` in `ByWrite`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1439:35 +a raw pointer to `std::cell::UnsafeCell` in `BySwap`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1452:35 +a raw pointer to `std::cell::UnsafeCell` in `ByReplace`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1464:35 +a raw pointer to `std::cell::UnsafeCell` in `ByBox`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1475:35 +a raw pointer to `std::cell::UnsafeCell` in `ByClosure`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1490:35 +a raw pointer to `std::cell::UnsafeCell` in `ByObject`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1503:35 +a raw pointer to `std::cell::UnsafeCell` in `ByInstance`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1516:35 +a raw pointer to `std::cell::UnsafeCell` in `BySwapped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1525:76 +a raw pointer to `std::cell::UnsafeCell` in `ByExchanged`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1536:30 +a raw pointer to `ByRefReplace` in `(u16, ByRefReplace)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1568:32 +a raw pointer to `ByRefTake` in `(u16, ByRefTake)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1576:32 +a raw pointer to `ByKeySet` in `(u16, ByKeySet)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1584:51 +a raw pointer to `ByKeyReplace` in `(u16, ByKeyReplace)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1592:55 +a raw pointer to `ByKeyTake` in `(u16, ByKeyTake)`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1599:52 +unsupported call to `core::str::::as_bytes_mut` at fixtures/reject/src/lib.rs:1607:13 +`core::str::::get_unchecked_mut` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1608:13 +`std::str::from_utf8_mut` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:1613:20 +unsupported call to `std::ptr::copy::<[u8; 4]>` at fixtures/reject/src/lib.rs:1681:3 +unsupported call to `std::ptr::copy_nonoverlapping::<[u8; 4]>` at fixtures/reject/src/lib.rs:1682:3 +unsupported call to `std::ptr::addr_eq::<[u8; 4], [u8; 4]>` at fixtures/reject/src/lib.rs:1683:14 +comparing `*mut [u8; 4]` at fixtures/reject/src/lib.rs:1683:41 +a cast from a pointer to `[u8; 4]` to one to `u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:1684:17 +a cast from `*const [u8; 4]` to `*const u8`, which reads the bytes of one type as another at fixtures/reject/src/lib.rs:1684:33 +unsupported call to `std::ptr::mut_ptr::::add` at fixtures/reject/src/lib.rs:1684:56 +unsupported call to `std::ptr::const_ptr::::offset` at fixtures/reject/src/lib.rs:1684:73 +a coercion of `*const [u8; 4]` to `*const [u8]`, a pointer to a slice at fixtures/reject/src/lib.rs:1685:28 +hashing `*const [u8; 4]` by its address, which JS has no counterpart of at fixtures/reject/src/lib.rs:1687:5 +unsupported call to `std::ptr::const_ptr::::len` at fixtures/reject/src/lib.rs:1688:58 +a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1697:15 +a raw pointer to `[u8; 3]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1697:18 +a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1697:37 +a raw pointer to `[u8; 2]` in an element, a payload, or a union field, which is not supported yet at fixtures/reject/src/lib.rs:1697:44 +a reference to `[u8; 4]`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:1704:26 +a raw pointer to `[u8; 4]` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1704:26 +a raw pointer to `[u8; 4]` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:1705:10 +const generic types are not supported: `Block` at fixtures/reject/src/lib.rs:2072:21 +`std::collections::LinkedList::::retain` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:2088:4 +`clone_from` of `std::collections::LinkedList`, whose items' `clone_from` is their own, which is not supported yet at fixtures/reject/src/lib.rs:2089:4 +`std::default::Default::default` with a mutable reference to a value JS copies, which its mapping would copy at fixtures/reject/src/lib.rs:2090:2 +a mapped guard of `{closure@fixtures/reject/src/lib.rs:2122:38: 2122:50}`, which JS can't write in place at fixtures/reject/src/lib.rs:2123:10 +a slice of one byte's place, which a byte slice can view only in an array of bytes at fixtures/reject/src/lib.rs:2129:2 +a slice or a cell of a mutable reference to `Reused` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2135:2 +`Clone::clone_from` of `std::vec::Vec`, whose `clone_from` is its own, which is not supported yet at fixtures/reject/src/lib.rs:2140:4 +unsupported call to `std::mem::size_of_val::` at fixtures/reject/src/lib.rs:2145:2 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2151:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2159:10 +a raw pointer to `(u32, u32)` in a variable assigned again while it may point there at fixtures/reject/src/lib.rs:2167:10 +a slice or a cell of a mutable reference to `std::cell::LazyCell` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2177:3 +an assignment through a reference to `std::sync::LazyLock` at fixtures/reject/src/lib.rs:2182:2 +a slice or a cell of a mutable reference to `std::thread::LocalKey` that names no place, which a whole write would replace only there at fixtures/reject/src/lib.rs:2188:2 overriding `Iterator::fold`, which std's adaptors call in place of `next` or beside it at fixtures/reject/src/lib.rs:125:2 -an iterator of the crate implementing `DoubleEndedIterator`, which is not supported yet at fixtures/reject/src/lib.rs:145:1 -overriding `Iterator::size_hint`, which std's adaptors call in place of `next` or beside it at fixtures/reject/src/lib.rs:173:2 -an iterator of the crate implementing `FusedIterator`, which is not supported yet at fixtures/reject/src/lib.rs:193:1 -`Hasher::write`, which is not supported yet at fixtures/reject/src/lib.rs:261:9 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Escaped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1072:43 -a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Called`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1086:28 -a raw pointer to `(u16, u16)` in `Copied`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1176:31 -a raw pointer to `std::cell::UnsafeCell` in `InArray`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1302:9 -a raw pointer to `std::cell::UnsafeCell` in `InTuple`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1306:9 -a raw pointer to `std::cell::UnsafeCell` in `InNested`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1310:9 -a raw pointer to `std::cell::UnsafeCell` in `InPayload`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1314:9 -a raw pointer to `std::cell::UnsafeCell` in `InField`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1318:9 -a raw pointer to `std::cell::UnsafeCell` in `InGeneric`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1322:9 -a raw pointer to `std::cell::UnsafeCell` in `InWritten`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1326:9 -a reference to `std::option::Option>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:2108:13 -a raw pointer to `(u8, u8)` in `([Cloned; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2225:23 -a raw pointer to `(u8, u8)` in `(Dropped, (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2225:23 -a raw pointer to `(u8, u8)` in `([Greatest; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2281:13 -a raw pointer to `(u8, u8)` in `([Touched; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2225:23 +overriding `DoubleEndedIterator::nth_back`, which std's adaptors call in place of `next` or beside it at fixtures/reject/src/lib.rs:150:2 +`Hasher::write`, which is not supported yet at fixtures/reject/src/lib.rs:232:9 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Escaped`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1043:43 +a raw pointer to `std::cell::UnsafeCell<(u16, u16)>` in `Called`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1057:28 +a raw pointer to `(u16, u16)` in `Copied`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1147:31 +a raw pointer to `std::cell::UnsafeCell` in `InArray`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1273:9 +a raw pointer to `std::cell::UnsafeCell` in `InTuple`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1277:9 +a raw pointer to `std::cell::UnsafeCell` in `InNested`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1281:9 +a raw pointer to `std::cell::UnsafeCell` in `InPayload`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1285:9 +a raw pointer to `std::cell::UnsafeCell` in `InField`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1289:9 +a raw pointer to `std::cell::UnsafeCell` in `InGeneric`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1293:9 +a raw pointer to `std::cell::UnsafeCell` in `InWritten`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:1297:9 +a reference to `std::option::Option>`, through which a raw pointer may be made, in a variable assigned again while that pointer may point there at fixtures/reject/src/lib.rs:2079:13 +a raw pointer to `(u8, u8)` in `([Cloned; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2196:23 +a raw pointer to `(u8, u8)` in `(Dropped, (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2196:23 +a raw pointer to `(u8, u8)` in `([Greatest; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2252:13 +a raw pointer to `(u8, u8)` in `([Touched; 2], (u8, u8))`, which the crate may put another object in place of at fixtures/reject/src/lib.rs:2196:23 diff --git a/ts/fixtures/reject/src/lib.rs b/ts/fixtures/reject/src/lib.rs index db1816a5a..f165d2be8 100644 --- a/ts/fixtures/reject/src/lib.rs +++ b/ts/fixtures/reject/src/lib.rs @@ -131,7 +131,7 @@ pub fn folds() -> usize { Folds.map(|b| b + 1).count() } -/// An iterator with a `next_back`, which an adaptor over it would need. +/// An iterator whose `nth_back` std's adaptors would call in place of its `next_back`. pub struct Backs; impl Iterator for Backs { @@ -146,10 +146,14 @@ impl DoubleEndedIterator for Backs { fn next_back(&mut self) -> Option { None } + + fn nth_back(&mut self, _n: usize) -> Option { + Some(0) + } } pub fn backs() -> usize { - Backs.rev().count() + Backs.rev().skip(1).count() } /// JS compares objects by identity, not by `PartialOrd`. @@ -160,41 +164,8 @@ pub fn keyed(range: std::ops::Range) -> bool { range.contains(&Key(2)) } -/// An iterator whose `size_hint` std's `collect` calls beside its `next`. -pub struct Hinted; - -impl Iterator for Hinted { - type Item = u8; - - fn next(&mut self) -> Option { - None - } - - fn size_hint(&self) -> (usize, Option) { - (0, Some(0)) - } -} - -pub fn hinted() -> Vec { - Hinted.collect() -} - -/// An iterator that `fuse` reads on past its end, since it says it stays ended. -pub struct Fused; - -impl Iterator for Fused { - type Item = u8; - - fn next(&mut self) -> Option { - None - } -} - -impl std::iter::FusedIterator for Fused {} - -pub fn fused() -> usize { - Fused.fuse().count() -} +/// A type of no bytes. +pub struct Bare; /// A `skip` of a zip std reads by index, which a zip by index drops a pair at a time. pub fn skipped_zip(v: &[u8]) -> usize { @@ -724,7 +695,7 @@ pub fn cell_field_replaced(n: u32) -> u32 { /// Pointers to places of no bytes, which Rust may put anywhere, `()`'s refused as made. pub fn units_compared() -> bool { - let (a, b, c, d) = ((), (), Fused, Fused); + let (a, b, c, d) = ((), (), Bare, Bare); std::ptr::eq(&raw const a, std::ptr::NonNull::from(&b).as_ptr()) && std::ptr::eq(&raw const c, &raw const d) } diff --git a/ts/fixtures/reject/ts.toml b/ts/fixtures/reject/ts.toml index 2ad9c0641..9b953acf3 100644 --- a/ts/fixtures/reject/ts.toml +++ b/ts/fixtures/reject/ts.toml @@ -23,8 +23,6 @@ roots = [ "keyed", "keyed_across", "place_bounds", - "hinted", - "fused", "skipped_zip", "zip_in_place", "replace_pinned_ref", diff --git a/ts/fixtures/stock/caller.ts b/ts/fixtures/stock/caller.ts index 50699cfd0..814cfbf57 100644 --- a/ts/fixtures/stock/caller.ts +++ b/ts/fixtures/stock/caller.ts @@ -1,5 +1,6 @@ // The harness, with inputs it names for `differential.ts`: `buf::reserves`' edges of -// `rt.BytesMut`'s limit, which only these reach, as each allocates 512 MiB. +// `rt.BytesMut`'s limit, which only these reach, as each allocates 512 MiB, and each of +// `hashlink`'s iterators read through every pick of steps from either end. import { op, run } from "./harness.ts"; @@ -8,4 +9,11 @@ export { run }; const reserves = op("buf::reserves"); /** Each edge but shared storage past the limit, which throws, read past by none and by some. */ -export const cases: Uint8Array[] = [0, 1, 2].flatMap((kind) => [0, 3].map((read) => Uint8Array.of(reserves, ...new TextEncoder().encode("edge"), kind, read))); +const edges = [0, 1, 2].flatMap((kind) => [0, 3].map((read) => Uint8Array.of(reserves, ...new TextEncoder().encode("edge"), kind, read))); + +/** `maps::linked_iters` of maps empty, of one, and fuller, each iterator and adaptor by each pick. */ +const linked = [0x00, 0x01, 0x02, 0x15, 0x0b, 0x3b].flatMap((len) => + [[], [0x00, 0x01, 0x00, 0x01, 0x00, 0x01], [0x07, 0x02, 0x05, 0x0b, 0x03, 0x00]].flatMap((steps) => Array.from({ length: 256 }, (_, pick) => Uint8Array.of(op("maps::linked_iters"), len, pick, ...steps))), +); + +export const cases: Uint8Array[] = [...edges, ...linked]; diff --git a/ts/fixtures/stock/expected/core/option.ts b/ts/fixtures/stock/expected/core/option.ts index 718575169..3d41f5d9b 100644 --- a/ts/fixtures/stock/expected/core/option.ts +++ b/ts/fixtures/stock/expected/core/option.ts @@ -9,6 +9,34 @@ export function unwrapOr$0r2bmpr(self: rt.u8 | undefined, default_: rt.u8): rt.u return self; } +export function unwrapOr$0l7j3f6(self: rt.usize | undefined, default_: rt.usize): rt.usize { + if (self === undefined) { + return default_; + } + return self; +} + +export function map$0h57z6f(self: [rt.u16, rt.Place] | undefined, f: (a0: [rt.u16, rt.Place]) => rt.Place): rt.Place | undefined { + if (self === undefined) { + return undefined; + } + return f(self); +} + +export function map$127uyaz(self: [rt.u16, rt.u32] | undefined, f: (a0: [rt.u16, rt.u32]) => rt.u16): rt.u16 | undefined { + if (self === undefined) { + return undefined; + } + return f(self); +} + +export function map$1st5iv4(self: [rt.u16, rt.u32] | undefined, f: (a0: [rt.u16, rt.u32]) => rt.u32): rt.u32 | undefined { + if (self === undefined) { + return undefined; + } + return f(self); +} + export function mapOr$1787w44(self: rt.Place | undefined, default_: rt.usize, f: (a0: rt.Place) => rt.usize): rt.usize { if (self === undefined) { return default_; @@ -23,6 +51,13 @@ export function mapOr$0iaogpf(self: [rt.u16, rt.u32] | undefined, default_: rt.u return f(self); } +export function mapOr$0yixjb2(self: rt.u16 | undefined, default_: rt.usize, f: (a0: rt.u16) => rt.usize): rt.usize { + if (self === undefined) { + return default_; + } + return f(self); +} + export function mapOr$1vcgixw(self: rt.u32 | undefined, default_: rt.usize, f: (a0: rt.u32) => rt.usize): rt.usize { if (self === undefined) { return default_; @@ -30,4 +65,11 @@ export function mapOr$1vcgixw(self: rt.u32 | undefined, default_: rt.usize, f: ( return f(self); } +export function mapOr$1noewr3(self: [rt.u16, rt.Place] | undefined, default_: rt.usize, f: (a0: [rt.u16, rt.Place]) => rt.usize): rt.usize { + if (self === undefined) { + return default_; + } + return f(self); +} + //# sourceMappingURL=option.ts.map diff --git a/ts/fixtures/stock/expected/harness.ts b/ts/fixtures/stock/expected/harness.ts index 383486577..27dbde1bf 100644 --- a/ts/fixtures/stock/expected/harness.ts +++ b/ts/fixtures/stock/expected/harness.ts @@ -3,7 +3,7 @@ import * as rt from "./rt.ts"; import { bytesMut, reserves, reads, writes, edits } from "./buf.ts"; import * as Owner from "./harness.Owner.ts"; -import { map as maps_map, table, capacity, linked } from "./maps.ts"; +import { map as maps_map, table, capacity, linked, linkedIters } from "./maps.ts"; /** * Each case's name and what it runs. The first byte picks one modulo their count, so a @@ -28,7 +28,9 @@ export function cases(): [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefine table(a011.data, a011.start, a011.length, a111); }] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined], ["maps::capacity", (a012: rt.ByteSlice, a112: rt.ByteVec): undefined => { capacity(a012.data, a012.start, a012.length, a112); - }] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined], ["maps::linked", linked as (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined]]; + }] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined], ["maps::linked", linked as (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined], ["maps::linked_iters", (a014: rt.ByteSlice, a114: rt.ByteVec): undefined => { + linkedIters(a014.data, a014.start, a014.length, a114); + }] as [string, (a0: rt.ByteSlice, a1: rt.ByteVec) => undefined]]; } /** Run one case. */ diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.Drain.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Drain.ts new file mode 100644 index 000000000..d7675847a --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Drain.ts @@ -0,0 +1,63 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32, pushFree$u16_u32 } from "../hashlink/linked_hash_map.ts"; +import * as Node from "../hashlink/linked_hash_map.Node.ts"; + +export class Drain { + free: rt.Place | undefined>; + head: Node.Node | undefined; + tail: Node.Node | undefined; + remaining: rt.usize; + marker: undefined; + + constructor(free: rt.Place | undefined>, head: Node.Node | undefined, tail: Node.Node | undefined, remaining: rt.usize, marker: undefined) { + this.free = free; + this.head = head; + this.tail = tail; + this.remaining = remaining; + this.marker = marker; + } +} + +export function next$iter_Iterator_u16_u32(self: Drain): [rt.u16, rt.u32] | rt.Done { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const head: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.head); + self.head = head.links.at0 as Node.Node; + const entry: [rt.u16, rt.u32] = Node.takeEntry$u16_u32(head); + pushFree$u16_u32(self.free, head); + return entry; + } + return rt.DONE; +} + +export function sizeHint$iter_Iterator_u16_u32(self: Drain): [rt.usize, rt.usize | undefined] { + return [self.remaining, self.remaining] as [rt.usize, rt.usize | undefined]; +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: Drain): [rt.u16, rt.u32] | undefined { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const tail: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.tail); + self.tail = tail.links.at4; + const entry: [rt.u16, rt.u32] = Node.takeEntry$u16_u32(tail); + pushFree$u16_u32(self.free, tail); + return entry; + } + return undefined; +} + +export function drop$ops_Drop_u16_u32(self: Drain): void { + const _4: rt.usize = self.remaining; + let iterStart: rt.usize = 0; + const iterEnd: rt.usize = _4; + while (iterStart++ < iterEnd) { + const tail: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.tail); + self.tail = tail.links.at4; + Node.takeEntry$u16_u32(tail); + pushFree$u16_u32(self.free, tail); + } +} + +//# sourceMappingURL=linked_hash_map.Drain.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.IntoIter.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.IntoIter.ts new file mode 100644 index 000000000..c17dbebe8 --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.IntoIter.ts @@ -0,0 +1,56 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32 } from "../hashlink/linked_hash_map.ts"; +import * as Node from "../hashlink/linked_hash_map.Node.ts"; + +export class IntoIter { + head: Node.Node | undefined; + tail: Node.Node | undefined; + remaining: rt.usize; + marker: undefined; + + constructor(head: Node.Node | undefined, tail: Node.Node | undefined, remaining: rt.usize, marker: undefined) { + this.head = head; + this.tail = tail; + this.remaining = remaining; + this.marker = marker; + } +} + +export function next$iter_Iterator_u16_u32(self: IntoIter): [rt.u16, rt.u32] | rt.Done { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const head: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.head); + self.head = head.links.at0 as Node.Node; + return Node.takeEntry$u16_u32(head); + } + return rt.DONE; +} + +export function sizeHint$iter_Iterator_u16_u32(self: IntoIter): [rt.usize, rt.usize | undefined] { + return [self.remaining, self.remaining] as [rt.usize, rt.usize | undefined]; +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: IntoIter): [rt.u16, rt.u32] | undefined { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const e: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.tail); + self.tail = e.links.at4; + return Node.takeEntry$u16_u32(e); + } + return undefined; +} + +export function drop$ops_Drop_u16_u32(self: IntoIter): void { + const _4: rt.usize = self.remaining; + let iterStart: rt.usize = 0; + const iterEnd: rt.usize = _4; + while (iterStart++ < iterEnd) { + const tail: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.tail); + self.tail = tail.links.at4; + Node.takeEntry$u16_u32(tail); + } +} + +//# sourceMappingURL=linked_hash_map.IntoIter.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.Iter.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Iter.ts new file mode 100644 index 000000000..c552b471d --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Iter.ts @@ -0,0 +1,38 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import * as Node from "../hashlink/linked_hash_map.Node.ts"; + +export interface Iter { + head: Node.Node; + tail: Node.Node; + remaining: rt.usize; + marker: undefined; +} + +export function next$iter_Iterator_u16_u32(self: Iter): [rt.u16, rt.u32] | rt.Done { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const _7: [rt.u16, rt.u32] = Node.entryRef$u16_u32(self.head); + self.head = self.head.links.at0 as Node.Node; + return [_7[0], _7[1]] as [rt.u16, rt.u32]; + } + return rt.DONE; +} + +export function sizeHint$iter_Iterator_u16_u32(self: Iter): [rt.usize, rt.usize | undefined] { + return [self.remaining, self.remaining] as [rt.usize, rt.usize | undefined]; +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: Iter): [rt.u16, rt.u32] | undefined { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const tail: Node.Node = self.tail; + self.tail = tail.links.at4; + const _10: [rt.u16, rt.u32] = Node.entryRef$u16_u32(tail); + return [_10[0], _10[1]] as [rt.u16, rt.u32]; + } + return undefined; +} + +//# sourceMappingURL=linked_hash_map.Iter.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.IterMut.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.IterMut.ts new file mode 100644 index 000000000..66ae0299c --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.IterMut.ts @@ -0,0 +1,40 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32 } from "../hashlink/linked_hash_map.ts"; +import * as Node from "../hashlink/linked_hash_map.Node.ts"; + +export interface IterMut { + head: Node.Node | undefined; + tail: Node.Node | undefined; + remaining: rt.usize; + marker: undefined; +} + +export function next$iter_Iterator_u16_u32(self: IterMut): [rt.u16, rt.Place] | rt.Done { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const head: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.head); + const _9: [rt.u16, rt.u32] = Node.entryMut$u16_u32(head); + self.head = head.links.at0 as Node.Node; + return [_9[0], rt.place(() => _9[1], (value) => _9[1] = value)] as [rt.u16, rt.Place]; + } + return rt.DONE; +} + +export function sizeHint$iter_Iterator_u16_u32(self: IterMut): [rt.usize, rt.usize | undefined] { + return [self.remaining, self.remaining] as [rt.usize, rt.usize | undefined]; +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: IterMut): [rt.u16, rt.Place] | undefined { + if (!(self.remaining === 0)) { + self.remaining = rt.usizeSub(self.remaining, 1); + const tail: Node.Node = asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.tail); + self.tail = tail.links.at4; + const _11: [rt.u16, rt.u32] = Node.entryMut$u16_u32(tail); + return [_11[0], rt.place(() => _11[1], (value) => _11[1] = value)] as [rt.u16, rt.Place]; + } + return undefined; +} + +//# sourceMappingURL=linked_hash_map.IterMut.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.Keys.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Keys.ts new file mode 100644 index 000000000..312f5ddcf --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Keys.ts @@ -0,0 +1,31 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { map$127uyaz as option_map$127uyaz } from "../core/option.ts"; +import * as linked_hash_map_Iter from "../hashlink/linked_hash_map.Iter.ts"; + +export interface Keys { + inner: linked_hash_map_Iter.Iter; +} + +export function next$iter_Iterator_u16_u32(self: Keys): rt.u16 | rt.Done { + return rt.iterFromOption(option_map$127uyaz(rt.iterToOption(linked_hash_map_Iter.next$iter_Iterator_u16_u32(self.inner)), (e: [rt.u16, rt.u32]): rt.u16 => { + return e[0]; + })); +} + +export function sizeHint$iter_Iterator_u16_u32(self: Keys): [rt.usize, rt.usize | undefined] { + return linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(self.inner); +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: Keys): rt.u16 | undefined { + return option_map$127uyaz(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(self.inner), (e: [rt.u16, rt.u32]): rt.u16 => { + return e[0]; + }); +} + +export function len$iter_ExactSizeIterator_u16_u32(self: Keys): rt.usize { + return rt.iterFrom(self.inner, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))).len(); +} + +//# sourceMappingURL=linked_hash_map.Keys.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.LinkedHashMap.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.LinkedHashMap.ts index aa64595fe..0d9e9bb4c 100644 --- a/ts/fixtures/stock/expected/hashlink/linked_hash_map.LinkedHashMap.ts +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.LinkedHashMap.ts @@ -1,14 +1,22 @@ // Generated by rust2-ts. Do not edit. import * as rt from "../rt.ts"; -import { drop$hashlink_linked_hash_map_DropFilteredValues_u16_u32 as lib_drop$hashlink_linked_hash_map_DropFilteredValues_u16_u32 } from "../lib.ts"; +import { drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState as lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState, drop$hashlink_linked_hash_map_DropFilteredValues_u16_u32 as lib_drop$hashlink_linked_hash_map_DropFilteredValues_u16_u32 } from "../lib.ts"; import { asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32, dropValueNodes$u16_u32, dropFreeNodes$u16_u32, hashNode$hash_RandomState_u16_u32 } from "../hashlink/linked_hash_map.ts"; +import * as linked_hash_map_Drain from "../hashlink/linked_hash_map.Drain.ts"; import * as DropFilteredValues from "../hashlink/linked_hash_map.DropFilteredValues.ts"; +import * as linked_hash_map_IntoIter from "../hashlink/linked_hash_map.IntoIter.ts"; +import type * as linked_hash_map_Iter from "../hashlink/linked_hash_map.Iter.ts"; +import type * as IterMut from "../hashlink/linked_hash_map.IterMut.ts"; +import type * as Keys from "../hashlink/linked_hash_map.Keys.ts"; import * as Node from "../hashlink/linked_hash_map.Node.ts"; import * as RawEntryBuilderMut from "../hashlink/linked_hash_map.RawEntryBuilderMut.ts"; import type * as RawEntryMut from "../hashlink/linked_hash_map.RawEntryMut.ts"; import * as RawOccupiedEntryMut from "../hashlink/linked_hash_map.RawOccupiedEntryMut.ts"; import * as RawVacantEntryMut from "../hashlink/linked_hash_map.RawVacantEntryMut.ts"; +import type * as ValueLinks from "../hashlink/linked_hash_map.ValueLinks.ts"; +import type * as linked_hash_map_Values from "../hashlink/linked_hash_map.Values.ts"; +import type * as ValuesMut from "../hashlink/linked_hash_map.ValuesMut.ts"; /** * A version of `HashMap` that has a user controllable order for its entries. @@ -53,6 +61,62 @@ export function isEmpty$u16_u32_hash_RandomState(self: LinkedHashMap): linked_hash_map_Iter.Iter { + let _4!: [Node.Node, Node.Node]; + if (self.values !== undefined) { + const _9: Node.Node = self.values; + _4 = [_9.links.at0 as Node.Node, _9.links.at4] as [Node.Node, Node.Node]; + } else { + _4 = [rt.NULL, rt.NULL] as [Node.Node, Node.Node]; + } + return { head: _4[0], tail: _4[1], remaining: len$u16_u32_hash_RandomState(self), marker: undefined }; +} + +export function iterMut$u16_u32_hash_RandomState(self: LinkedHashMap): IterMut.IterMut { + let _4!: [Node.Node | undefined, Node.Node | undefined]; + if (self.values !== undefined) { + const _9: Node.Node = self.values; + _4 = [_9.links.at0 as Node.Node, _9.links.at4] as [Node.Node | undefined, Node.Node | undefined]; + } else { + _4 = [undefined, undefined] as [Node.Node | undefined, Node.Node | undefined]; + } + return { head: _4[0], tail: _4[1], remaining: len$u16_u32_hash_RandomState(self), marker: undefined }; +} + +export function drain$u16_u32_hash_RandomState(self: LinkedHashMap): linked_hash_map_Drain.Drain { + let _4!: [Node.Node | undefined, Node.Node | undefined]; + if (self.values !== undefined) { + const values: Node.Node = self.values; + const _9: Node.Node = values; + const next: Node.Node = _9.links.at0 as Node.Node; + const prev: Node.Node = _9.links.at4; + const _11: ValueLinks.ValueLinks = { next: values, prev: values }; + const _14: Node.Node = values; + _14.links.at0 = _11.next; + _14.links.at4 = _11.prev; + _4 = [next, prev] as [Node.Node | undefined, Node.Node | undefined]; + } else { + _4 = [undefined, undefined] as [Node.Node | undefined, Node.Node | undefined]; + } + const head: Node.Node | undefined = _4[0]; + const tail: Node.Node | undefined = _4[1]; + const len: rt.usize = len$u16_u32_hash_RandomState(self); + rt.hashClear(self.table, undefined); + return new linked_hash_map_Drain.Drain(rt.place(() => self.free, (value) => self.free = value), head, tail, len, undefined); +} + +export function keys$u16_u32_hash_RandomState(self: LinkedHashMap): Keys.Keys { + return { inner: iter$u16_u32_hash_RandomState(self) }; +} + +export function values$u16_u32_hash_RandomState(self: LinkedHashMap): linked_hash_map_Values.Values { + return { inner: iter$u16_u32_hash_RandomState(self) }; +} + +export function valuesMut$u16_u32_hash_RandomState(self: LinkedHashMap): ValuesMut.ValuesMut { + return { inner: iterMut$u16_u32_hash_RandomState(self) }; +} + export function front$u16_u32_hash_RandomState(self: LinkedHashMap): [rt.u16, rt.u32] | undefined { if (!isEmpty$u16_u32_hash_RandomState(self)) { const _9: [rt.u16, rt.u32] = Node.entryRef$u16_u32(asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.values).links.at0 as Node.Node); @@ -187,4 +251,27 @@ export function drop$ops_Drop_u16_u32_hash_RandomState(self: LinkedHashMap): linked_hash_map_IntoIter.IntoIter { + let _4!: [Node.Node | undefined, Node.Node | undefined]; + if (self.values !== undefined) { + const _9: Node.Node = self.values; + const head2: Node.Node = _9.links.at0 as Node.Node; + const tail2: Node.Node = _9.links.at4; + asPtr$hashlink_linked_hash_map_OptNonNullExt_hashlink_linked_hash_map_Node_u16_u32_Option_ptr_NonNull_hashlink_linked_hash_map_Node_u16_u32(self.values); + self.values = undefined; + _4 = [head2, tail2] as [Node.Node | undefined, Node.Node | undefined]; + } else { + _4 = [undefined, undefined] as [Node.Node | undefined, Node.Node | undefined]; + } + const head: Node.Node | undefined = _4[0]; + const tail: Node.Node | undefined = _4[1]; + const len: rt.usize = len$u16_u32_hash_RandomState(self); + const taken = self.free; + self.free = undefined; + dropFreeNodes$u16_u32(taken); + rt.hashClear(self.table, undefined); + lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState(self); + return new linked_hash_map_IntoIter.IntoIter(head, tail, len, undefined); +} + //# sourceMappingURL=linked_hash_map.LinkedHashMap.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.Values.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Values.ts new file mode 100644 index 000000000..c869096d2 --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.Values.ts @@ -0,0 +1,31 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { map$1st5iv4 as option_map$1st5iv4 } from "../core/option.ts"; +import * as linked_hash_map_Iter from "../hashlink/linked_hash_map.Iter.ts"; + +export interface Values { + inner: linked_hash_map_Iter.Iter; +} + +export function next$iter_Iterator_u16_u32(self: Values): rt.u32 | rt.Done { + return rt.iterFromOption(option_map$1st5iv4(rt.iterToOption(linked_hash_map_Iter.next$iter_Iterator_u16_u32(self.inner)), (e: [rt.u16, rt.u32]): rt.u32 => { + return e[1]; + })); +} + +export function sizeHint$iter_Iterator_u16_u32(self: Values): [rt.usize, rt.usize | undefined] { + return linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(self.inner); +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: Values): rt.u32 | undefined { + return option_map$1st5iv4(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(self.inner), (e: [rt.u16, rt.u32]): rt.u32 => { + return e[1]; + }); +} + +export function len$iter_ExactSizeIterator_u16_u32(self: Values): rt.usize { + return rt.iterFrom(self.inner, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))).len(); +} + +//# sourceMappingURL=linked_hash_map.Values.ts.map diff --git a/ts/fixtures/stock/expected/hashlink/linked_hash_map.ValuesMut.ts b/ts/fixtures/stock/expected/hashlink/linked_hash_map.ValuesMut.ts new file mode 100644 index 000000000..beb590cfc --- /dev/null +++ b/ts/fixtures/stock/expected/hashlink/linked_hash_map.ValuesMut.ts @@ -0,0 +1,31 @@ +// Generated by rust2-ts. Do not edit. + +import * as rt from "../rt.ts"; +import { map$0h57z6f as option_map$0h57z6f } from "../core/option.ts"; +import * as IterMut from "../hashlink/linked_hash_map.IterMut.ts"; + +export interface ValuesMut { + inner: IterMut.IterMut; +} + +export function next$iter_Iterator_u16_u32(self: ValuesMut): rt.Place | rt.Done { + return rt.iterFromOption(option_map$0h57z6f(rt.iterToOption(IterMut.next$iter_Iterator_u16_u32(self.inner)), (e: [rt.u16, rt.Place]): rt.Place => { + return e[1]; + })); +} + +export function sizeHint$iter_Iterator_u16_u32(self: ValuesMut): [rt.usize, rt.usize | undefined] { + return IterMut.sizeHint$iter_Iterator_u16_u32(self.inner); +} + +export function nextBack$iter_DoubleEndedIterator_u16_u32(self: ValuesMut): rt.Place | undefined { + return option_map$0h57z6f(IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(self.inner), (e: [rt.u16, rt.Place]): rt.Place => { + return e[1]; + }); +} + +export function len$iter_ExactSizeIterator_u16_u32(self: ValuesMut): rt.usize { + return rt.iterFrom(self.inner, (it: IterMut.IterMut) => IterMut.next$iter_Iterator_u16_u32(it), undefined, (it: IterMut.IterMut) => IterMut.sizeHint$iter_Iterator_u16_u32(it), (it: IterMut.IterMut) => rt.iterFromOption(IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(it))).len(); +} + +//# sourceMappingURL=linked_hash_map.ValuesMut.ts.map diff --git a/ts/fixtures/stock/expected/lib.ts b/ts/fixtures/stock/expected/lib.ts index c283edb14..5861ce541 100644 --- a/ts/fixtures/stock/expected/lib.ts +++ b/ts/fixtures/stock/expected/lib.ts @@ -1,7 +1,9 @@ // Generated by rust2-ts. Do not edit. import * as rt from "./rt.ts"; +import * as linked_hash_map_Drain from "./hashlink/linked_hash_map.Drain.ts"; import * as DropFilteredValues from "./hashlink/linked_hash_map.DropFilteredValues.ts"; +import * as linked_hash_map_IntoIter from "./hashlink/linked_hash_map.IntoIter.ts"; import * as LinkedHashMap from "./hashlink/linked_hash_map.LinkedHashMap.ts"; import * as Remainder$drop_value_nodes from "./hashlink/linked_hash_map.Remainder$drop_value_nodes.ts"; @@ -20,10 +22,18 @@ export function drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState(_1: LinkedH LinkedHashMap.drop$ops_Drop_u16_u32_hash_RandomState(_1); } +export function drop$hashlink_linked_hash_map_Drain_u16_u32(_1: linked_hash_map_Drain.Drain): void { + linked_hash_map_Drain.drop$ops_Drop_u16_u32(_1); +} + export function drop$hashlink_linked_hash_map_DropFilteredValues_u16_u32(_1: DropFilteredValues.DropFilteredValues): void { DropFilteredValues.drop$ops_Drop_u16_u32(_1); } +export function drop$hashlink_linked_hash_map_IntoIter_u16_u32(_1: linked_hash_map_IntoIter.IntoIter): void { + linked_hash_map_IntoIter.drop$ops_Drop_u16_u32(_1); +} + export function drop$hashlink_linked_hash_map_drop_value_nodes_Remainder_u16_u32(_1: Remainder$drop_value_nodes.Remainder): void { Remainder$drop_value_nodes.drop$drop_value_nodes_ops_Drop_u16_u32(_1); } diff --git a/ts/fixtures/stock/expected/maps.ts b/ts/fixtures/stock/expected/maps.ts index ecaf2902d..2ec9ba0fa 100644 --- a/ts/fixtures/stock/expected/maps.ts +++ b/ts/fixtures/stock/expected/maps.ts @@ -1,9 +1,16 @@ // Generated by rust2-ts. Do not edit. import * as rt from "./rt.ts"; -import { copy$tuple2_u16_u32, drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState as lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState } from "./lib.ts"; -import { unwrapOr$0r2bmpr as option_unwrapOr$0r2bmpr, mapOr$1787w44 as option_mapOr$1787w44, mapOr$0iaogpf as option_mapOr$0iaogpf, mapOr$1vcgixw as option_mapOr$1vcgixw } from "./core/option.ts"; +import { copy$tuple2_u16_u32, drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState as lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState, drop$hashlink_linked_hash_map_Drain_u16_u32 as lib_drop$hashlink_linked_hash_map_Drain_u16_u32, drop$hashlink_linked_hash_map_IntoIter_u16_u32 as lib_drop$hashlink_linked_hash_map_IntoIter_u16_u32 } from "./lib.ts"; +import { unwrapOr$0r2bmpr as option_unwrapOr$0r2bmpr, unwrapOr$0l7j3f6 as option_unwrapOr$0l7j3f6, mapOr$1787w44 as option_mapOr$1787w44, mapOr$0iaogpf as option_mapOr$0iaogpf, mapOr$0yixjb2 as option_mapOr$0yixjb2, mapOr$1vcgixw as option_mapOr$1vcgixw, mapOr$1noewr3 as option_mapOr$1noewr3 } from "./core/option.ts"; +import * as linked_hash_map_Drain from "./hashlink/linked_hash_map.Drain.ts"; +import * as linked_hash_map_IntoIter from "./hashlink/linked_hash_map.IntoIter.ts"; +import * as linked_hash_map_Iter from "./hashlink/linked_hash_map.Iter.ts"; +import * as IterMut from "./hashlink/linked_hash_map.IterMut.ts"; +import * as Keys from "./hashlink/linked_hash_map.Keys.ts"; import * as LinkedHashMap from "./hashlink/linked_hash_map.LinkedHashMap.ts"; +import * as linked_hash_map_Values from "./hashlink/linked_hash_map.Values.ts"; +import * as ValuesMut from "./hashlink/linked_hash_map.ValuesMut.ts"; /** A length, capacity, or value, as four bytes. */ export function put(out: rt.ByteVec, n: rt.usize): void { @@ -641,4 +648,350 @@ export function linked(data: rt.ByteSlice, out: rt.ByteVec): void { lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState(m); } +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_Drain_u16_u32_maps_linked_iters_closure6(it: linked_hash_map_Drain.Drain, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: [rt.u16, rt.u32]) => rt.usize): void { + let item!: [rt.u16, rt.u32] | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(linked_hash_map_Drain.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = linked_hash_map_Drain.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_Drain_u16_u32, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Drain.Drain) => rt.iterFromOption(linked_hash_map_Drain.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_Drain_u16_u32, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Drain.Drain) => rt.iterFromOption(linked_hash_map_Drain.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } + put(out, option_mapOr$0iaogpf(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = linked_hash_map_Drain.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter<[rt.u16, rt.u32]> = rt.iterRev(rt.iterFrom(it, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_Drain_u16_u32, (it: linked_hash_map_Drain.Drain) => linked_hash_map_Drain.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Drain.Drain) => rt.iterFromOption(linked_hash_map_Drain.nextBack$iter_DoubleEndedIterator_u16_u32(it)))); + while (true) { + const _41: [rt.u16, rt.u32] | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } + rt.drop(iter2); +} + +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_IntoIter_u16_u32_maps_linked_iters_closure5(it: linked_hash_map_IntoIter.IntoIter, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: [rt.u16, rt.u32]) => rt.usize): void { + let item!: [rt.u16, rt.u32] | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(linked_hash_map_IntoIter.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = linked_hash_map_IntoIter.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_IntoIter_u16_u32, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_IntoIter.IntoIter) => rt.iterFromOption(linked_hash_map_IntoIter.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_IntoIter_u16_u32, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_IntoIter.IntoIter) => rt.iterFromOption(linked_hash_map_IntoIter.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } + put(out, option_mapOr$0iaogpf(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = linked_hash_map_IntoIter.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter<[rt.u16, rt.u32]> = rt.iterRev(rt.iterFrom(it, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.next$iter_Iterator_u16_u32(it), lib_drop$hashlink_linked_hash_map_IntoIter_u16_u32, (it: linked_hash_map_IntoIter.IntoIter) => linked_hash_map_IntoIter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_IntoIter.IntoIter) => rt.iterFromOption(linked_hash_map_IntoIter.nextBack$iter_DoubleEndedIterator_u16_u32(it)))); + while (true) { + const _41: [rt.u16, rt.u32] | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } + rt.drop(iter2); +} + +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_IterMut_u16_u32_maps_linked_iters_closure1(it: IterMut.IterMut, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: [rt.u16, rt.Place]) => rt.usize): void { + let item!: [rt.u16, rt.Place] | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(IterMut.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: IterMut.IterMut) => IterMut.next$iter_Iterator_u16_u32(it), undefined, (it: IterMut.IterMut) => IterMut.sizeHint$iter_Iterator_u16_u32(it), (it: IterMut.IterMut) => rt.iterFromOption(IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: IterMut.IterMut) => IterMut.next$iter_Iterator_u16_u32(it), undefined, (it: IterMut.IterMut) => IterMut.sizeHint$iter_Iterator_u16_u32(it), (it: IterMut.IterMut) => rt.iterFromOption(IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } + put(out, option_mapOr$1noewr3(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = IterMut.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter<[rt.u16, rt.Place]> = rt.iterRev(rt.iterFrom(it, (it: IterMut.IterMut) => IterMut.next$iter_Iterator_u16_u32(it), undefined, (it: IterMut.IterMut) => IterMut.sizeHint$iter_Iterator_u16_u32(it), (it: IterMut.IterMut) => rt.iterFromOption(IterMut.nextBack$iter_DoubleEndedIterator_u16_u32(it)))); + while (true) { + const _41: [rt.u16, rt.Place] | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } +} + +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_Iter_u16_u32_maps_linked_iters_closure0(it: linked_hash_map_Iter.Iter, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: [rt.u16, rt.u32]) => rt.usize): void { + let item!: [rt.u16, rt.u32] | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(linked_hash_map_Iter.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))), n); + } + put(out, option_mapOr$0iaogpf(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter<[rt.u16, rt.u32]> = rt.iterRev(rt.iterFrom(it, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it)))); + while (true) { + const _41: [rt.u16, rt.u32] | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } +} + +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_Keys_u16_u32_maps_linked_iters_closure3(it: Keys.Keys, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: rt.u16) => rt.usize): void { + let item!: rt.u16 | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(Keys.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = Keys.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: Keys.Keys) => Keys.next$iter_Iterator_u16_u32(it), undefined, (it: Keys.Keys) => Keys.sizeHint$iter_Iterator_u16_u32(it), (it: Keys.Keys) => rt.iterFromOption(Keys.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: Keys.Keys) => Keys.len$iter_ExactSizeIterator_u16_u32(it)), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: Keys.Keys) => Keys.next$iter_Iterator_u16_u32(it), undefined, (it: Keys.Keys) => Keys.sizeHint$iter_Iterator_u16_u32(it), (it: Keys.Keys) => rt.iterFromOption(Keys.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: Keys.Keys) => Keys.len$iter_ExactSizeIterator_u16_u32(it)), n); + } + put(out, option_mapOr$0yixjb2(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = Keys.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter = rt.iterRev(rt.iterFrom(it, (it: Keys.Keys) => Keys.next$iter_Iterator_u16_u32(it), undefined, (it: Keys.Keys) => Keys.sizeHint$iter_Iterator_u16_u32(it), (it: Keys.Keys) => rt.iterFromOption(Keys.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: Keys.Keys) => Keys.len$iter_ExactSizeIterator_u16_u32(it))); + while (true) { + const _41: rt.u16 | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } +} + +/** + * `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, + * `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from + * the back. + */ +export function ends$hashlink_linked_hash_map_Values_u16_u32_maps_linked_iters_closure4(it: linked_hash_map_Values.Values, steps: rt.ByteSlice, out: rt.ByteVec, f: (a0: rt.u32) => rt.usize): void { + let item!: rt.u32 | undefined; + const iter: rt.Iter = rt.iterTake(rt.iterSlice(rt.byteSliceView(steps)), 6); + while (true) { + const _9: rt.u8 | rt.Done = iter.next(); + if (_9 === rt.DONE) { + break; + } + const step: rt.u8 = _9; + const n: rt.usize = rt.usizeRem(step >> 2 as rt.usize, 3); + const _20: rt.u8 = rt.u8Rem(step, 4); + if (_20 === 0) { + item = rt.iterToOption(linked_hash_map_Values.next$iter_Iterator_u16_u32(it)); + } else if (_20 === 1) { + item = linked_hash_map_Values.nextBack$iter_DoubleEndedIterator_u16_u32(it); + } else if (_20 === 2) { + item = rt.iterNth(rt.iterFrom(it, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Values.Values) => rt.iterFromOption(linked_hash_map_Values.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: linked_hash_map_Values.Values) => linked_hash_map_Values.len$iter_ExactSizeIterator_u16_u32(it)), n); + } else { + item = rt.iterNthBack(rt.iterFrom(it, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Values.Values) => rt.iterFromOption(linked_hash_map_Values.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: linked_hash_map_Values.Values) => linked_hash_map_Values.len$iter_ExactSizeIterator_u16_u32(it)), n); + } + put(out, option_mapOr$1vcgixw(item, 256, f)); + const _32: [rt.usize, rt.usize | undefined] = linked_hash_map_Values.sizeHint$iter_Iterator_u16_u32(it); + const lower: rt.usize = _32[0]; + const upper: rt.usize | undefined = _32[1]; + put(out, lower); + put(out, option_unwrapOr$0l7j3f6(upper, 256)); + } + const iter2: rt.Iter = rt.iterRev(rt.iterFrom(it, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Values.Values) => rt.iterFromOption(linked_hash_map_Values.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: linked_hash_map_Values.Values) => linked_hash_map_Values.len$iter_ExactSizeIterator_u16_u32(it))); + while (true) { + const _41: rt.u32 | rt.Done = iter2.next(); + if (_41 === rt.DONE) { + break; + } + put(out, f(_41)); + } +} + +/** + * `hashlink::LinkedHashMap`'s iterators, of up to 11 entries in the order `data`'s first + * byte inserts them, each read from either end and through std's adaptors. + */ +export function linkedIters(dataData: Uint8Array, dataStart: number, dataLen: number, out: rt.ByteVec): void { + let _15!: rt.u16; + let it!: ValuesMut.ValuesMut; + const _34: (a0: [rt.u16, rt.u32]) => rt.usize = (_2: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_2[0] as rt.usize, 4096), _2[1] as rt.usize); + }; + let _104: boolean = false; + if (dataLen >= 2) { + const m: LinkedHashMap.LinkedHashMap = LinkedHashMap.withHasher$u16_u32_hash_RandomState(rt.randomState()); + _104 = true; + const _12: rt.u16 = rt.u8Rem(dataData[dataStart], 12) as rt.u16; + let iterStart: rt.u16 = 0; + const iterEnd: rt.u16 = _12; + while ((_15 = iterStart++) < iterEnd) { + const i: rt.u16 = _15; + LinkedHashMap.insert$u16_u32_hash_RandomState(m, rt.u16Rem(rt.u16Add(rt.u16Mul(i, 5), rt.u8Shr(dataData[dataStart], 4) as rt.u16), 12), rt.u32Mul(i as rt.u32, 3)); + } + const k: rt.usize = rt.u8Shr(dataData[dataStart + 1], 3) as rt.usize; + const _35: rt.u8 = rt.u8Rem(dataData[dataStart + 1], 8); + if (_35 === 0) { + ends$hashlink_linked_hash_map_Iter_u16_u32_maps_linked_iters_closure0(LinkedHashMap.iter$u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (_215: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_215[0] as rt.usize, 4096), _215[1] as rt.usize); + }); + } else if (_35 === 1) { + ends$hashlink_linked_hash_map_IterMut_u16_u32_maps_linked_iters_closure1(LinkedHashMap.iterMut$u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (_214: [rt.u16, rt.Place]): rt.usize => { + _214[1].v = rt.u32Add(_214[1].v, 100); + return _214[0] as rt.usize; + }); + const _42: linked_hash_map_Iter.Iter = LinkedHashMap.iter$u16_u32_hash_RandomState(m); + const _44: (a0: [rt.u16, rt.u32]) => undefined = (e2: [rt.u16, rt.u32]): undefined => { + put(out, _34(e2)); + }; + rt.iterForEach(rt.iterFrom(_42, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))), _44); + } else if (_35 === 2) { + ends$hashlink_linked_hash_map_Keys_u16_u32_maps_linked_iters_closure3(LinkedHashMap.keys$u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (k5: rt.u16): rt.usize => { + return k5 as rt.usize; + }); + } else if (_35 === 3) { + ends$hashlink_linked_hash_map_Values_u16_u32_maps_linked_iters_closure4(LinkedHashMap.values$u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (v6: rt.u32): rt.usize => { + return v6 as rt.usize; + }); + } else if (_35 === 4) { + _104 = false; + ends$hashlink_linked_hash_map_IntoIter_u16_u32_maps_linked_iters_closure5(LinkedHashMap.intoIter$iter_IntoIterator_u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (_213: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_213[0] as rt.usize, 4096), _213[1] as rt.usize); + }); + } else if (_35 === 5) { + ends$hashlink_linked_hash_map_Drain_u16_u32_maps_linked_iters_closure6(LinkedHashMap.drain$u16_u32_hash_RandomState(m), new rt.ByteSlice(dataData, dataStart + 2, dataLen - 2), out, (_212: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_212[0] as rt.usize, 4096), _212[1] as rt.usize); + }); + put(out, LinkedHashMap.len$u16_u32_hash_RandomState(m)); + } else if (_35 === 6) { + it = LinkedHashMap.valuesMut$u16_u32_hash_RandomState(m); + const _64: rt.usize = rt.usizeRem(k, 4); + put(out, option_mapOr$1787w44(rt.iterNthBack(rt.iterFrom(it, (it: ValuesMut.ValuesMut) => ValuesMut.next$iter_Iterator_u16_u32(it), undefined, (it: ValuesMut.ValuesMut) => ValuesMut.sizeHint$iter_Iterator_u16_u32(it), (it: ValuesMut.ValuesMut) => rt.iterFromOption(ValuesMut.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: ValuesMut.ValuesMut) => ValuesMut.len$iter_ExactSizeIterator_u16_u32(it)), _64), 256, (v: rt.Place): rt.usize => { + return v.v as rt.usize; + })); + put(out, ValuesMut.len$iter_ExactSizeIterator_u16_u32(it)); + rt.iterForEach(rt.iterRev(rt.iterFrom(it, (it: ValuesMut.ValuesMut) => ValuesMut.next$iter_Iterator_u16_u32(it), undefined, (it: ValuesMut.ValuesMut) => ValuesMut.sizeHint$iter_Iterator_u16_u32(it), (it: ValuesMut.ValuesMut) => rt.iterFromOption(ValuesMut.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: ValuesMut.ValuesMut) => ValuesMut.len$iter_ExactSizeIterator_u16_u32(it))), (v2: rt.Place): undefined => { + v2.v = rt.u32Add(v2.v, 1); + }); + rt.iterForEach(rt.iterFrom(LinkedHashMap.values$u16_u32_hash_RandomState(m), (it: linked_hash_map_Values.Values) => linked_hash_map_Values.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Values.Values) => linked_hash_map_Values.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Values.Values) => rt.iterFromOption(linked_hash_map_Values.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: linked_hash_map_Values.Values) => linked_hash_map_Values.len$iter_ExactSizeIterator_u16_u32(it)), (v3: rt.u32): undefined => { + put(out, v3 as rt.usize); + }); + } else { + const it2: linked_hash_map_Iter.Iter = LinkedHashMap.iter$u16_u32_hash_RandomState(m); + put(out, option_mapOr$0iaogpf(rt.iterToOption(linked_hash_map_Iter.next$iter_Iterator_u16_u32(it2)), 256, (_210: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_210[0] as rt.usize, 4096), _210[1] as rt.usize); + })); + put(out, rt.iterFrom(it2, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it))).len()); + const rest: rt.usize[] = rt.iterToArray(rt.iterMap(rt.iterSkip(rt.iterRev(rt.iterFrom(it2, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.next$iter_Iterator_u16_u32(it), undefined, (it: linked_hash_map_Iter.Iter) => linked_hash_map_Iter.sizeHint$iter_Iterator_u16_u32(it), (it: linked_hash_map_Iter.Iter) => rt.iterFromOption(linked_hash_map_Iter.nextBack$iter_DoubleEndedIterator_u16_u32(it)))), rt.usizeRem(k, 4)), (_211: [rt.u16, rt.u32]): rt.usize => { + return rt.usizeAdd(rt.usizeMul(_211[0] as rt.usize, 4096), _211[1] as rt.usize); + }), "next", 4); + put(out, rt.vecCapacity(rest, 4)); + rt.iterForEach(rt.iterSlice(rest), (e: rt.usize): undefined => { + put(out, e); + }); + put(out, option_unwrapOr$0l7j3f6(rt.iterRposition(rt.iterFrom(LinkedHashMap.keys$u16_u32_hash_RandomState(m), (it: Keys.Keys) => Keys.next$iter_Iterator_u16_u32(it), undefined, (it: Keys.Keys) => Keys.sizeHint$iter_Iterator_u16_u32(it), (it: Keys.Keys) => rt.iterFromOption(Keys.nextBack$iter_DoubleEndedIterator_u16_u32(it)), (it: Keys.Keys) => Keys.len$iter_ExactSizeIterator_u16_u32(it)), (k2: rt.u16): boolean => { + return rt.u16Rem(k2, 2) === 0; + }), 256)); + } + if (_104) { + lib_drop$hashlink_LinkedHashMap_u16_u32_hash_RandomState(m); + } + _104 = false; + } +} + //# sourceMappingURL=maps.ts.map diff --git a/ts/fixtures/stock/src/harness.rs b/ts/fixtures/stock/src/harness.rs index 441621070..f2ccaeb3d 100644 --- a/ts/fixtures/stock/src/harness.rs +++ b/ts/fixtures/stock/src/harness.rs @@ -24,6 +24,7 @@ fn cases() -> Vec<(&'static str, Case)> { ("maps::table", crate::maps::table), ("maps::capacity", crate::maps::capacity), ("maps::linked", crate::maps::linked), + ("maps::linked_iters", crate::maps::linked_iters), ] } diff --git a/ts/fixtures/stock/src/maps.rs b/ts/fixtures/stock/src/maps.rs index 4a16a2914..2abacd090 100644 --- a/ts/fixtures/stock/src/maps.rs +++ b/ts/fixtures/stock/src/maps.rs @@ -1,7 +1,7 @@ //! `hashbrown`'s tables, which translation maps to the runtime's map as it maps std's, and //! `hashlink`'s, which translate from their source over a `HashTable`. A hash table's //! iteration order is unspecified, so only what does not depend on it is written, but a -//! linked map's order is its own, and written as it is. +//! linked map's order is its own, and written as it is, read from either end. use std::collections::hash_map::RandomState; use std::hash::BuildHasher; @@ -384,3 +384,72 @@ pub fn linked(data: &[u8], out: &mut Vec) { put(out, v as usize); } } + +/// `it` read by each byte of `steps` from the front or the back, by `next`, `next_back`, +/// `nth`, or `nth_back`, each item by `f` and then its size hint, and then the rest from +/// the back. +fn ends(mut it: I, steps: &[u8], out: &mut Vec, f: impl Fn(I::Item) -> usize) { + for &step in steps.iter().take(6) { + let n = usize::from(step >> 2) % 3; + let item = match step % 4 { + 0 => it.next(), + 1 => it.next_back(), + 2 => it.nth(n), + _ => it.nth_back(n), + }; + put(out, item.map_or(0x100, &f)); + let (lower, upper) = it.size_hint(); + put(out, lower); + put(out, upper.unwrap_or(0x100)); + } + for item in it.rev() { + put(out, f(item)); + } +} + +/// `hashlink::LinkedHashMap`'s iterators, of up to 11 entries in the order `data`'s first +/// byte inserts them, each read from either end and through std's adaptors. +pub fn linked_iters(data: &[u8], out: &mut Vec) { + let [len, pick, steps @ ..] = data else { + return; + }; + let mut m: LinkedHashMap = LinkedHashMap::with_hasher(RandomState::new()); + for i in 0..u16::from(len % 12) { + m.insert((i * 5 + u16::from(len >> 4)) % 12, u32::from(i) * 3); + } + let k = usize::from(pick >> 3); + let entry = |(k, v): (&u16, &u32)| usize::from(*k) * 0x1000 + *v as usize; + match pick % 8 { + 0 => ends(m.iter(), steps, out, entry), + 1 => { + ends(m.iter_mut(), steps, out, |(k, v)| { + *v += 100; + usize::from(*k) + }); + m.iter().for_each(|e| put(out, entry(e))); + } + 2 => ends(m.keys(), steps, out, |k| usize::from(*k)), + 3 => ends(m.values(), steps, out, |v| *v as usize), + 4 => ends(m.into_iter(), steps, out, |(k, v)| usize::from(k) * 0x1000 + v as usize), + 5 => { + ends(m.drain(), steps, out, |(k, v)| usize::from(k) * 0x1000 + v as usize); + put(out, m.len()); + } + 6 => { + let mut it = m.values_mut(); + put(out, it.nth_back(k % 4).map_or(0x100, |v| *v as usize)); + put(out, it.len()); + it.rev().for_each(|v| *v += 1); + m.values().for_each(|v| put(out, *v as usize)); + } + _ => { + let mut it = m.iter(); + put(out, it.next().map_or(0x100, entry)); + put(out, it.len()); + let rest: Vec = it.rev().skip(k % 4).map(entry).collect(); + put(out, rest.capacity()); + rest.into_iter().for_each(|e| put(out, e)); + put(out, m.keys().rposition(|k| k % 2 == 0).unwrap_or(0x100)); + } + } +} diff --git a/ts/runtime/rt/iter.ts b/ts/runtime/rt/iter.ts index 6f1c6437e..ce608998e 100644 --- a/ts/runtime/rt/iter.ts +++ b/ts/runtime/rt/iter.ts @@ -60,6 +60,19 @@ export function exactHint(n: number): SizeHint { return [n, n]; } +/** + * std's default `ExactSizeIterator::len` of `it`: its size hint's lower bound, which + * panics unless the upper bound is the same. + */ +function hintLen(it: Iter): number { + const [lower, upper] = it.sizeHint(); + if (upper !== lower) { + const left = upper === undefined ? "None" : `Some(${upper})`; + panic(`assertion \`left == right\` failed\n left: ${left}\n right: Some(${lower})`); + } + return lower; +} + /** std's hint of an adaptor that may yield fewer than `it`, and no more: none at least, and `it`'s upper bound. */ function fewer(it: Iter): SizeHint { return [0, it.sizeHint()[1]]; @@ -522,9 +535,13 @@ export function iterSuccessors(first: T | undefined | None, succ: (item: T) = return new SuccessorsIter(first, succ, drop, none); } -/** An `impl Iterator` of the translated crate, which `next` calls the `next` of, and `drop` drops. */ -export function iterFrom(source: S, next: (source: S) => T | Done, drop?: Drop): Iter { - return new FromNext(source, next, drop); +/** + * An `impl Iterator` of the translated crate, which `next` calls the `next` of, and `drop` + * drops. `hint`, `back`, and `len` call its own `size_hint`, `next_back`, and `len`, where + * it has them. + */ +export function iterFrom(source: S, next: (source: S) => T | Done, drop?: Drop, hint?: (source: S) => SizeHint, back?: (source: S) => T | Done, len?: (source: S) => number): Iter { + return new FromNext(source, next, drop, hint, back, len); } /** An iterator borrowed by `&mut`, which std's adaptors take as one: its items, but never it to drop. */ @@ -1825,26 +1842,49 @@ class OptionIter extends Iter implements Disposable { } } -/** An iterator whose `next` is a function of its source, which `drop` drops. */ +/** + * An iterator whose `next` is a function of its source, which `drop` drops, as are its + * `size_hint`, `next_back`, and `len` where it has them. + */ class FromNext extends Iter implements Disposable { private readonly source: S; private readonly step: (source: S) => T | Done; private drop: Drop | undefined; + private readonly hint: ((source: S) => SizeHint) | undefined; + private readonly back: ((source: S) => T | Done) | undefined; + private readonly exact: ((source: S) => number) | undefined; - constructor(source: S, step: (source: S) => T | Done, drop?: Drop) { + constructor(source: S, step: (source: S) => T | Done, drop?: Drop, hint?: (source: S) => SizeHint, back?: (source: S) => T | Done, exact?: (source: S) => number) { super(); this.source = source; this.step = step; this.drop = drop; + this.hint = hint; + this.back = back; + this.exact = exact; } next(): T | Done { return this.step(this.source); } + /** Only an iterator with its own `next_back` is read from the back. */ + override nextBack(): T | Done { + return (this.back as (source: S) => T | Done)(this.source); + } + + override sizeHint(): SizeHint { + return this.hint === undefined ? super.sizeHint() : this.hint(this.source); + } + + /** Its own, or std's, of its size hint. */ + override len(): number { + return this.exact === undefined ? hintLen(this) : this.exact(this.source); + } + /** Its source cloned by `h.v`, as the crate's own `Clone` of it. */ override clone(h?: Clones): Iter { - return new FromNext(cloned(this.source, h?.v), this.step, this.drop); + return new FromNext(cloned(this.source, h?.v), this.step, this.drop, this.hint, this.back, this.exact); } [Symbol.dispose](): void { @@ -2414,8 +2454,9 @@ class ZipIter extends Iter<[A, B]> implements Disposable { return [a, b]; } + /** std's, of its size hint. */ override len(): number { - return Math.min(this.a.len(), this.b.len()); + return hintLen(this); } /** std's: the shorter side's, where either knows its upper bound. */ @@ -2657,8 +2698,9 @@ class SkipIter extends Adaptor { return this.len() > 0 ? this.inner.nextBack() : DONE; } + /** std's, of its size hint. */ override len(): number { - return Math.max(this.inner.len() - this.n, 0); + return hintLen(this); } /** std's: what it skips and `n` more in one step, and the rest of `n` if that saturated a `usize`. */ @@ -2696,7 +2738,8 @@ class SkipIter extends Adaptor { /** * std's: past what it skips by `nth`, one short of where `next` reads, then its iterator - * folded, and from the back, its iterator folded down to what it skips. + * folded, and from the back, its iterator folded down to what it skips, by its length + * as the fold starts. */ override folded(fold = false): Iter { const inner = this.inner.folded(fold); @@ -2711,7 +2754,14 @@ class SkipIter extends Adaptor { } return inner.next(); }; - return new Folded(front, () => (this.len() > 0 ? inner.nextBack() : DONE)); + let left: number | undefined; + const back = (): T | Done => { + left ??= this.len(); + if (left === 0) return DONE; + left--; + return inner.nextBack(); + }; + return new Folded(front, back); } /** std's: past what it skips by `nth`, and then its iterator's own. */ @@ -2773,8 +2823,9 @@ class TakeIter extends Adaptor { return this.inner.nthBack(Math.max(this.inner.len() - n, 0), this.drop); } + /** std's, of its size hint. */ override len(): number { - return Math.min(this.inner.len(), this.n); + return hintLen(this); } override advanceBy(n: number, drop?: Drop): number { @@ -3022,8 +3073,9 @@ class StepByIter extends Adaptor { return this.firstTake ? (rem === 0 ? this.step : rem - 1) : rem; } + /** std's, of its size hint. */ override len(): number { - return this.size(this.inner.len()); + return hintLen(this); } override sizeHint(): SizeHint { @@ -3659,9 +3711,9 @@ export class Peekable extends Adaptor { return peeked; } + /** std's, of its size hint. */ override len(): number { - if (!this.peeked) return this.inner.len(); - return this.item === DONE ? 0 : this.inner.len() + 1; + return hintLen(this); } override [Symbol.dispose](): void { diff --git a/ts/src/lower/iter.rs b/ts/src/lower/iter.rs index 73205ac10..350017a46 100644 --- a/ts/src/lower/iter.rs +++ b/ts/src/lower/iter.rs @@ -2,7 +2,7 @@ //! `next` returns an item or `rt.DONE`, and whose adaptors and consumers are runtime //! functions taking the iterator first: `rt.iterMap(it, f)`. The crate's own `impl //! Iterator` keeps that protocol in its `next`, and joins std's adaptors through -//! `rt.iterFrom`. +//! `rt.iterFrom`, with its own `size_hint`, `next_back`, and `len`. use rustc_hir::def_id::DefId; use rustc_middle::ty::{self, Instance, Ty, TyCtxt, TypeVisitableExt}; @@ -51,34 +51,27 @@ impl<'tcx> Translator<'_, 'tcx> { /// The crate's own iterator a `ty` is, through any references: its `next`, whose /// instance the translation names. fn own_next<'tcx>(b: &Body<'_, '_, 'tcx>, ty: Ty<'tcx>) -> Option> { - let tcx = b.t.tcx; - let ty = ty.peel_refs(); - // Over parameters, only a census's instance, which never runs, would call it. - if !matches!(ty.kind(), ty::Adt(adt, _) if b.t.own(adt.did())) || ty.has_param() || ty.has_aliases() { - return None; - } - let (next, _) = trait_items(tcx)?; - Instance::try_resolve(tcx, b.t.typing_env_pub(), next, tcx.mk_args(&[ty.into()])).ok()? + own_method(b, ty, "Iterator", "next") } +/// The methods of std's iterator traits, by trait, that an iterator of the crate may have +/// of its own: `rt.iterFrom` calls each where std's adaptors do. +const OWN: [(&str, &str); 4] = [ + ("Iterator", "next"), + ("Iterator", "size_hint"), + ("DoubleEndedIterator", "next_back"), + ("ExactSizeIterator", "len"), +]; + /// Refuse an `impl Iterator` of the crate, whose `next` is `next_fn`, that std's adaptors -/// would read other than through `next`: one that overrides `fold`, `nth`, or `size_hint`, -/// which they call in its place or beside it, that has a `next_back` or `len`, which this -/// protocol lacks, or that is a `FusedIterator`, which `fuse` reads on past its end. +/// would read other than through the methods in `OWN`: one whose `Iterator` or +/// `DoubleEndedIterator` impl overrides another, such as `fold` or `nth_back`, which they +/// call in its place. pub fn check_impl(t: &mut Translator<'_, '_>, next_fn: DefId) { let tcx = t.tcx; let Some(imp) = tcx.impl_of_assoc(next_fn) else { return; }; - for item in tcx.associated_items(imp).in_definition_order() { - let name = item.name(); - if item.is_fn() && name != rustc_span::sym::next { - t.err( - tcx.def_span(item.def_id), - format!("overriding `Iterator::{name}`, which std's adaptors call in place of `next` or beside it"), - ); - } - } let ty::Adt(adt, _) = tcx.type_of(imp).instantiate_identity().skip_norm_wip().kind() else { return; }; @@ -89,20 +82,53 @@ pub fn check_impl(t: &mut Translator<'_, '_>, next_fn: DefId) { continue; } let path = library::std_path(tcx, tcx.impl_trait_id(other)); - if let Some(name) = path.last().filter(|n| { - matches!( - n.as_str(), - "DoubleEndedIterator" | "ExactSizeIterator" | "FusedIterator" - ) - }) { - t.err( - tcx.def_span(other), - format!("an iterator of the crate implementing `{name}`, which is not supported yet"), - ); + let Some(tr) = path.last().filter(|tr| OWN.iter().any(|(own, _)| own == tr)) else { + continue; + }; + for item in tcx.associated_items(other).in_definition_order() { + let name = item.name(); + if item.is_fn() && !OWN.contains(&(tr.as_str(), name.as_str())) { + t.err( + tcx.def_span(item.def_id), + format!("overriding `{tr}::{name}`, which std's adaptors call in place of `next` or beside it"), + ); + } } } } +/// The crate's own `tr::name` of an iterator of type `ty`, through any references, if `ty` +/// is one of the crate's own that overrides it or has it as a required method. +fn own_method<'tcx>(b: &Body<'_, '_, 'tcx>, ty: Ty<'tcx>, tr: &str, name: &str) -> Option> { + let tcx = b.t.tcx; + let ty = ty.peel_refs(); + // Over parameters, only a census's instance, which never runs, would call it. + if !matches!(ty.kind(), ty::Adt(adt, _) if b.t.own(adt.did())) || ty.has_param() || ty.has_aliases() { + return None; + } + if !implements(b.t, ty, tr) { + return None; + } + let method = tcx + .associated_items(core_trait(tcx, tr)?) + .filter_by_name_unhygienic(rustc_span::Symbol::intern(name)) + .next()? + .def_id; + let instance = Instance::try_resolve(tcx, b.t.typing_env_pub(), method, tcx.mk_args(&[ty.into()])).ok()??; + (instance.def_id() != method).then_some(instance) +} + +/// `iter.next_back()` of the crate's own iterator of type `ty`, as the protocol returns it: +/// an item or `rt.DONE`. +fn own_back<'tcx>(b: &mut Body<'_, '_, 'tcx>, ty: Ty<'tcx>, iter: Expr) -> Option { + let instance = own_method(b, ty, "DoubleEndedIterator", "next_back")?; + let item = b.t.iter_item(ty.peel_refs())?; + let sym = b.t.instance(instance); + let none = b.t.none_arg(item); + let option = Expr::Sym(sym).call(vec![iter]); + Some(Expr::rt("iterFromOption", [option].into_iter().chain(none).collect())) +} + /// `iter.next()` by the protocol, for an iterator of type `ty`: an item or `rt.DONE`. pub fn next<'tcx>(b: &mut Body<'_, '_, 'tcx>, ty: Ty<'tcx>, iter: Expr) -> Expr { match own_next(b, ty) { @@ -135,15 +161,34 @@ pub fn into_iter<'tcx>(b: &mut Body<'_, '_, 'tcx>, ty: Ty<'tcx>, value: Expr, sp let param_ty = b.t.ty(ty.peel_refs(), span); let it = "it".to_string(); let next = Expr::Sym(sym).call(vec![Expr::ident(&it)]); - let param = Param { - name: it, - ty: Some(param_ty), + // Each of its own methods `rt.iterFrom` calls, as a function of the source. + let of = |body: Option| match body { + Some(body) => { + let param = Param { + name: it.clone(), + ty: Some(param_ty.clone()), + }; + Expr::Lambda(vec![param], Box::new(body)) + } + None => Expr::undefined(), }; - let mut args = vec![value, Expr::Lambda(vec![param], Box::new(next))]; - if owned && b.t.drops(ty) { - args.push(b.t.dropper(ty, span)); - } - Expr::rt("iterFrom", args) + let call = |b: &mut Body<'_, '_, 'tcx>, tr: &str, name: &str| { + let instance = own_method(b, ty, tr, name)?; + Some(Expr::Sym(b.t.instance(instance)).call(vec![Expr::ident(&it)])) + }; + let drop = match owned && b.t.drops(ty) { + true => b.t.dropper(ty, span), + false => Expr::undefined(), + }; + let own = [ + call(b, "Iterator", "size_hint"), + own_back(b, ty, Expr::ident(&it)), + call(b, "ExactSizeIterator", "len"), + ]; + Expr::rt( + "iterFrom", + tail(vec![value, of(Some(next))], [vec![drop], own.map(of).to_vec()].concat()), + ) } // One borrowed by `&mut`, which std's adaptors may drop once it ends, but which // is its owner's to drop, and which a consumer reads on through the borrow @@ -427,8 +472,12 @@ pub fn call<'tcx>( if matches!(name, "next" | "next_back" | "nth_back") { let item = match name { "next" => next(b, self_ty, recv), - "next_back" => recv.member("nextBack").call(Vec::new()), + "next_back" => match own_back(b, self_ty, recv.clone()) { + Some(back) => back, + None => recv.member("nextBack").call(Vec::new()), + }, _ => { + let recv = into_iter(b, self_ty, recv, span)?; let droppers = [b.t.dropper(item, span)].into_iter().chain(none).collect(); return Some(Expr::rt("iterNthBack", tail([vec![recv], rest].concat(), droppers))); } @@ -822,11 +871,15 @@ pub(super) fn size_of<'tcx>(b: &mut Body<'_, '_, 'tcx>, ty: Ty<'tcx>, span: Span layout(b, ty, span).map_or_else(|e| e, |(size, _)| Expr::lit(size.to_string())) } -/// Whether an iterator of type `ty`, with `held` beside it, drops and is a `FusedIterator`, -/// which std's `fuse` and `flatten` keep once it ends rather than drop: `true` or `false`. +/// Whether an iterator of type `ty` is a `FusedIterator`, which std's `fuse` and `flatten` +/// keep once it ends rather than drop, and read on from: `true` or `false`. Only one that +/// drops, with `held` beside it, or holds an iterator of the crate's own, which may yield +/// again past its end, can tell. fn fused<'tcx>(b: &mut Body<'_, '_, 'tcx>, ty: Ty<'tcx>, held: Option>) -> Expr { let drops = b.t.drops(ty) || held.is_some_and(|held| b.t.drops(held)); - Expr::lit(match drops && implements(b.t, ty, "FusedIterator") { + let own = (ty.walk().filter_map(|arg| arg.as_type())) + .any(|t| matches!(t.kind(), ty::Adt(adt, _) if b.t.own(adt.did())) && b.t.iter_item(t).is_some()); + Expr::lit(match (drops || own) && implements(b.t, ty, "FusedIterator") { true => "true", false => "false", }) diff --git a/ts/tests/fixtures.rs b/ts/tests/fixtures.rs index 2f0b2d825..af3128ccf 100644 --- a/ts/tests/fixtures.rs +++ b/ts/tests/fixtures.rs @@ -488,18 +488,17 @@ fn bind() { /// A package and its dependency translate as one program, trait objects of the /// dependency's trait and its safe twin of its `unsafe` included, and run as native Rust -/// does. Its `unsafe` that nothing binds is refused at its span, and so are its iterator -/// that runs from either end, a module of the package's that would share the -/// dependency's files, and two instances whose suffixes are alike. +/// does. Its `unsafe` that nothing binds is refused at its span, and so are a module of +/// the package's that would share the dependency's files and two instances whose +/// suffixes are alike. #[test] fn crates() { let out = translated("crates"); snapshot("crates", &out); typecheck(&out); differential("crates-fixture", &[], &out, "harness.ts", 1_000); - let cases: [(&str, &str, &[&str]); 4] = [ + let cases: [(&str, &str, &[&str]); 3] = [ ("refused", "refused.toml", &[]), - ("rev", "ts.toml", &["--", "--features", "rev"]), ("shared", "ts.toml", &["--", "--features", "shared"]), ("alike", "alike.toml", &["--", "--features", "alike"]), ]; From 9902e8e33d8fcf4eee251a7deb8ac9ce1cc8da1e Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 04:13:30 -0800 Subject: [PATCH 3/6] chore(quest): finish a crate's own iterator traits Co-Authored-By: Claude Opus 5.5 --- quest/m2/ts-model/README.md | 1 - quest/m2/ts-model/iter-traits.md | 23 ----------------------- 2 files changed, 24 deletions(-) delete mode 100644 quest/m2/ts-model/iter-traits.md diff --git a/quest/m2/ts-model/README.md b/quest/m2/ts-model/README.md index bbabea6b8..757d5ade5 100644 --- a/quest/m2/ts-model/README.md +++ b/quest/m2/ts-model/README.md @@ -51,4 +51,3 @@ Public API: the translator's output for moq-net's model. - [The std calls moq's main added to the model](/quest/m2/ts-model/main-std.md) - `VecDeque::range`, and `str::rsplit_once` and `split_terminator` by a `char`, translate - [A crate's own hasher](/quest/m2/ts-model/own-hasher.md) - hashlink's default hasher, a crate's own `Hasher`, hashes keys as native's does -- [A crate's own iterator traits](/quest/m2/ts-model/iter-traits.md) - hashlink's double-ended, exact-size, and fused iterators, and their `size_hint` diff --git a/quest/m2/ts-model/iter-traits.md b/quest/m2/ts-model/iter-traits.md deleted file mode 100644 index 20d9e1900..000000000 --- a/quest/m2/ts-model/iter-traits.md +++ /dev/null @@ -1,23 +0,0 @@ -# [M] A crate's own double-ended, exact-size, and fused iterators - -## Goal - -[rust2-ts](/ts/README.md) translates a crate's own iterator that implements -`DoubleEndedIterator`, `ExactSizeIterator`, or `FusedIterator`, or overrides `size_hint`, as -hashlink's do, so std's adaptors and collectors call them where native's does, proven by -differential tests against native Rust. - -## Plan - -Found by [#398](https://github.com/moq-dev/rust2/pull/398): once hashbrown translated, 39 of -the model's census refusals were in these impls on hashlink's iterators, such as -`LinkedHashMap`'s `Iter`, `Keys`, and `Drain`. They predate #398. - -- Read the refusals from `just ts census` on `ts/moq/model.toml` first, and close each kind. -- `next_back`, `len`, and an overridden `size_hint` are the crate's methods, called wherever - std's adaptors and collectors call them, `rev`, `last`, a `collect`'s reserve, and the rest, - and nowhere they don't. -- `FusedIterator` is only a marker, but `fuse` skips its guard for one, which a differential - test with an iterator that yields again after `None` shows. - -Public API: the translator's output. From c4ef5a3fd73fc442e21ee405d52f18ae18876be1 Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 04:43:59 -0800 Subject: [PATCH 4/6] fix(ts): read a crate iterator's length where std's adaptors do Co-Authored-By: Claude Opus 5.5 --- ts/fixtures/lang/caller.ts | 2 +- ts/fixtures/lang/expected/core/option.ts | 7 ++ ts/fixtures/lang/expected/ends.ts | 126 ++++++++++++++++------- ts/fixtures/lang/src/ends.rs | 17 ++- ts/runtime/rt/iter.ts | 43 +++++--- 5 files changed, 143 insertions(+), 52 deletions(-) diff --git a/ts/fixtures/lang/caller.ts b/ts/fixtures/lang/caller.ts index 9e1e435f0..e29226250 100644 --- a/ts/fixtures/lang/caller.ts +++ b/ts/fixtures/lang/caller.ts @@ -870,7 +870,7 @@ const capacityCases = [ * few steps through each of its methods. */ const endsCases = [0x00, 0x03, 0x0f, 0x15, 0x27, 0x36, 0x2f].flatMap((shape) => - [[], [0x01, 0x00], [0x0a, 0x03], [0x05, 0x06, 0x04, 0x0f]].flatMap((steps) => + [[], [0x01, 0x00], [0x0a, 0x0d, 0x03], [0x05, 0x06, 0x04, 0x0f]].flatMap((steps) => Array.from({ length: 4 * 256 }, (_, i) => Uint8Array.of(...op("ends::ends"), i % 4, shape, i >> 2, ...steps)), ), ); diff --git a/ts/fixtures/lang/expected/core/option.ts b/ts/fixtures/lang/expected/core/option.ts index 9cb686cd7..4d4f1a77a 100644 --- a/ts/fixtures/lang/expected/core/option.ts +++ b/ts/fixtures/lang/expected/core/option.ts @@ -735,6 +735,13 @@ export function map$0gl6wke(self: [rt.usize, string] | undefined, f: (a0: [rt.us return f(self); } +export function map$1sj2ls1(self: [rt.usize, rt.u8] | undefined, f: (a0: [rt.usize, rt.u8]) => rt.u8): rt.u8 | undefined { + if (self === undefined) { + return undefined; + } + return f(self); +} + export function map$0a57co2(self: rt.u32 | undefined, f: (a0: rt.u32) => rt.u8): rt.u8 | undefined { if (self === undefined) { return undefined; diff --git a/ts/fixtures/lang/expected/ends.ts b/ts/fixtures/lang/expected/ends.ts index 1b0f0e174..8c0774381 100644 --- a/ts/fixtures/lang/expected/ends.ts +++ b/ts/fixtures/lang/expected/ends.ts @@ -1,7 +1,7 @@ // Generated by rust2-ts. Do not edit. import * as rt from "./rt.ts"; -import { unwrapOr$0r2bmpr as option_unwrapOr$0r2bmpr, map$05nbzug as option_map$05nbzug, mapOr$02k4ito as option_mapOr$02k4ito } from "./core/option.ts"; +import { unwrapOr$0r2bmpr as option_unwrapOr$0r2bmpr, map$05nbzug as option_map$05nbzug, map$1sj2ls1 as option_map$1sj2ls1, mapOr$02k4ito as option_mapOr$02k4ito } from "./core/option.ts"; import * as ends_Counted from "./ends.Counted.ts"; import * as Flicker from "./ends.Flicker.ts"; import * as Lapse from "./ends.Lapse.ts"; @@ -68,22 +68,26 @@ export function ends(kind: rt.u8, dataData: Uint8Array, dataStart: number, dataL } else if (_29 === 4) { putHint(out, ends_Run.sizeHint$iter_Iterator(run)); } else if (_29 === 5) { - put(out, rt.iterToOption(rt.iterRev(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))).next())); + if (!((step & 8) === 0)) { + put(out, ends_Run.nextBack$iter_DoubleEndedIterator(run)); + } else { + put(out, rt.iterToOption(rt.iterRev(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))).next())); + } } else if (_29 === 6) { rt.byteVecPush(out, rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len() & 0xff); } else { - const _58: rt.usize = rt.usizeRem(step >> 3 as rt.usize, 4); - put(out, rt.iterNth(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _58)); + const _62: rt.usize = rt.usizeRem(step >> 3 as rt.usize, 4); + put(out, rt.iterNth(rt.iterFrom(run, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _62)); } } const k: rt.usize = rt.u8Shr(dataData[dataStart + 1], 4) as rt.usize; b4: { - const _67: rt.u8 = rt.u8Rem(kind, 4); - if (_67 === 0) { + const _71: rt.u8 = rt.u8Rem(kind, 4); + if (_71 === 0) { consumed$ends_Run(run, rt.u8Rem(dataData[dataStart + 1], 16), k, out); - } else if (_67 === 1) { + } else if (_71 === 1) { consumed$ends_Counted({ _0: run }, rt.u8Rem(dataData[dataStart + 1], 16), k, out); - } else if (_67 === 2) { + } else if (_71 === 2) { fuses(dataData[dataStart + 1], out); } else { let bits: rt.u8 = dataData[dataStart + 1]; @@ -109,6 +113,7 @@ export function ends(kind: rt.u8, dataData: Uint8Array, dataStart: number, dataL /** `it`, consumed by std's adaptor or consumer `pick`, with `k` its count where it takes one. */ export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: rt.usize, out: rt.ByteVec): void { + let _32!: rt.u8 | undefined; if (pick === 0) { putVec(out, rt.iterToByteVec(rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))), "next")); } else if (pick === 1) { @@ -116,8 +121,8 @@ export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: } else if (pick === 2) { rt.byteVecPush(out, rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))).len() & 0xff); } else if (pick === 3) { - rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)))), (_2: [rt.usize, rt.u8]): Uint8Array => { - return Uint8Array.of(_2[0] & 0xff, _2[1]); + rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)))), (_211: [rt.usize, rt.u8]): Uint8Array => { + return Uint8Array.of(_211[0] & 0xff, _211[1]); }, (value: Uint8Array) => rt.iterSlice(value), false, 2), "next"); } else if (pick === 4) { rt.iterExtendBytes(out, rt.iterRev(rt.iterSkip(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k)), "next"); @@ -128,15 +133,39 @@ export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: const _28: rt.usize = rt.max(k, 1); rt.iterExtendBytes(out, rt.iterRev(rt.iterStepBy(rt.iterFrom(_27, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), _28)), "next"); } else if (pick === 7) { - put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b4: rt.u8): boolean => { - return rt.u8Rem(b4, 3) === 0; - }), (i: rt.usize): rt.u8 => { - return i & 0xff; + put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b8: rt.u8): boolean => { + return rt.u8Rem(b8, 3) === 0; + }), (i3: rt.usize): rt.u8 => { + return i3 & 0xff; })); } else if (pick === 8) { - put(out, rt.iterRfind(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), (b3: rt.u8): boolean => { - return rt.u8Rem(b3, 3) === 0; - })); + const _33: rt.usize = rt.usizeRem(k, 4); + if (_33 === 0) { + const _37: ends_Counted.Counted = it; + const _38: rt.usize = rt.usizeDiv(k, 4); + _32 = rt.iterRfind(rt.iterSkip(rt.iterFrom(_37, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), _38), (b7: rt.u8): boolean => { + return rt.u8Rem(b7, 3) === 0; + }); + } else if (_33 === 1) { + const _42: ends_Counted.Counted = it; + const _43: rt.usize = rt.usizeDiv(k, 4); + _32 = rt.iterRfind(rt.iterTake(rt.iterFrom(_42, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), _43), (b6: rt.u8): boolean => { + return rt.u8Rem(b6, 3) === 0; + }); + } else if (_33 === 2) { + _32 = option_map$1sj2ls1(rt.iterRfind(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))), (_2: [rt.usize, rt.u8]): boolean => { + return rt.u8Rem(rt.u8Add(_2[0] & 0xff, _2[1]), 3) === 0; + }), (_210: [rt.usize, rt.u8]): rt.u8 => { + return (_210[0] & 0xff) ^ _210[1]; + }); + } else { + const _51: ends_Counted.Counted = it; + const _52: rt.usize = rt.usizeAdd(rt.usizeDiv(k, 4), 1); + _32 = rt.iterRfind(rt.iterStepBy(rt.iterFrom(_51, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), _52), (b3: rt.u8): boolean => { + return rt.u8Rem(b3, 3) === 0; + }); + } + put(out, _32); } else if (pick === 9) { put(out, rt.iterLast(rt.iterRev(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it))))); } else if (pick === 10) { @@ -145,16 +174,16 @@ export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: })), k), "next"); } else if (pick === 11) { const v: rt.ByteVec = rt.byteVecFrom(Uint8Array.of(170)); - const _45: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k); - rt.iterExtendBytes(v, _45, "next"); + const _67: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), k); + rt.iterExtendBytes(v, _67, "next"); putVec(out, v); rt.byteVecPush(out, ends_Counted.len$iter_ExactSizeIterator(it) & 0xff); } else if (pick === 12) { const zip: rt.Iter<[rt.u8, rt.u8]> = rt.iterZip(rt.iterFrom(it, (it: ends_Counted.Counted) => ends_Counted.next$iter_Iterator(it), undefined, (it: ends_Counted.Counted) => ends_Counted.sizeHint$iter_Iterator(it), (it: ends_Counted.Counted) => rt.iterFromOption(ends_Counted.nextBack$iter_DoubleEndedIterator(it)), (it: ends_Counted.Counted) => ends_Counted.len$iter_ExactSizeIterator(it)), new rt.Range(0, 5)); while (true) { - const _57: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); - if (_57 !== undefined) { - rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_57[0], _57[1])), undefined, true); + const _79: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); + if (_79 !== undefined) { + rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_79[0], _79[1])), undefined, true); } else { break; } @@ -176,6 +205,7 @@ export function consumed$ends_Counted(it: ends_Counted.Counted, pick: rt.u8, k: /** `it`, consumed by std's adaptor or consumer `pick`, with `k` its count where it takes one. */ export function consumed$ends_Run(it: ends_Run.Run, pick: rt.u8, k: rt.usize, out: rt.ByteVec): void { + let _32!: rt.u8 | undefined; if (pick === 0) { putVec(out, rt.iterToByteVec(rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))), "next")); } else if (pick === 1) { @@ -183,8 +213,8 @@ export function consumed$ends_Run(it: ends_Run.Run, pick: rt.u8, k: rt.usize, ou } else if (pick === 2) { rt.byteVecPush(out, rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))).len() & 0xff); } else if (pick === 3) { - rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))))), (_2: [rt.usize, rt.u8]): Uint8Array => { - return Uint8Array.of(_2[0] & 0xff, _2[1]); + rt.iterExtendBytes(out, rt.iterFlatMap(rt.iterRev(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))))), (_211: [rt.usize, rt.u8]): Uint8Array => { + return Uint8Array.of(_211[0] & 0xff, _211[1]); }, (value: Uint8Array) => rt.iterSlice(value), false, 2), "next"); } else if (pick === 4) { rt.iterExtendBytes(out, rt.iterRev(rt.iterSkip(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k)), "next"); @@ -195,15 +225,39 @@ export function consumed$ends_Run(it: ends_Run.Run, pick: rt.u8, k: rt.usize, ou const _28: rt.usize = rt.max(k, 1); rt.iterExtendBytes(out, rt.iterRev(rt.iterStepBy(rt.iterFrom(_27, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _28)), "next"); } else if (pick === 7) { - put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b4: rt.u8): boolean => { - return rt.u8Rem(b4, 3) === 0; - }), (i: rt.usize): rt.u8 => { - return i & 0xff; + put(out, option_map$05nbzug(rt.iterRposition(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b8: rt.u8): boolean => { + return rt.u8Rem(b8, 3) === 0; + }), (i3: rt.usize): rt.u8 => { + return i3 & 0xff; })); } else if (pick === 8) { - put(out, rt.iterRfind(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), (b3: rt.u8): boolean => { - return rt.u8Rem(b3, 3) === 0; - })); + const _33: rt.usize = rt.usizeRem(k, 4); + if (_33 === 0) { + const _37: ends_Run.Run = it; + const _38: rt.usize = rt.usizeDiv(k, 4); + _32 = rt.iterRfind(rt.iterSkip(rt.iterFrom(_37, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _38), (b7: rt.u8): boolean => { + return rt.u8Rem(b7, 3) === 0; + }); + } else if (_33 === 1) { + const _42: ends_Run.Run = it; + const _43: rt.usize = rt.usizeDiv(k, 4); + _32 = rt.iterRfind(rt.iterTake(rt.iterFrom(_42, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _43), (b6: rt.u8): boolean => { + return rt.u8Rem(b6, 3) === 0; + }); + } else if (_33 === 2) { + _32 = option_map$1sj2ls1(rt.iterRfind(rt.iterEnumerate(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))), (_2: [rt.usize, rt.u8]): boolean => { + return rt.u8Rem(rt.u8Add(_2[0] & 0xff, _2[1]), 3) === 0; + }), (_210: [rt.usize, rt.u8]): rt.u8 => { + return (_210[0] & 0xff) ^ _210[1]; + }); + } else { + const _51: ends_Run.Run = it; + const _52: rt.usize = rt.usizeAdd(rt.usizeDiv(k, 4), 1); + _32 = rt.iterRfind(rt.iterStepBy(rt.iterFrom(_51, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), _52), (b3: rt.u8): boolean => { + return rt.u8Rem(b3, 3) === 0; + }); + } + put(out, _32); } else if (pick === 9) { put(out, rt.iterLast(rt.iterRev(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it)))))); } else if (pick === 10) { @@ -212,16 +266,16 @@ export function consumed$ends_Run(it: ends_Run.Run, pick: rt.u8, k: rt.usize, ou })), k), "next"); } else if (pick === 11) { const v: rt.ByteVec = rt.byteVecFrom(Uint8Array.of(170)); - const _45: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k); - rt.iterExtendBytes(v, _45, "next"); + const _67: rt.Iter = rt.iterTake(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), k); + rt.iterExtendBytes(v, _67, "next"); putVec(out, v); rt.byteVecPush(out, rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))).len() & 0xff); } else if (pick === 12) { const zip: rt.Iter<[rt.u8, rt.u8]> = rt.iterZip(rt.iterFrom(it, (it: ends_Run.Run) => ends_Run.next$iter_Iterator(it), undefined, (it: ends_Run.Run) => ends_Run.sizeHint$iter_Iterator(it), (it: ends_Run.Run) => rt.iterFromOption(ends_Run.nextBack$iter_DoubleEndedIterator(it))), new rt.Range(0, 5)); while (true) { - const _57: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); - if (_57 !== undefined) { - rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_57[0], _57[1])), undefined, true); + const _79: [rt.u8, rt.u8] | undefined = rt.iterToOption(zip.nextBack()); + if (_79 !== undefined) { + rt.iterExtendBytes(out, rt.iterSlice(Uint8Array.of(_79[0], _79[1])), undefined, true); } else { break; } diff --git a/ts/fixtures/lang/src/ends.rs b/ts/fixtures/lang/src/ends.rs index bf4beb67a..3241450f6 100644 --- a/ts/fixtures/lang/src/ends.rs +++ b/ts/fixtures/lang/src/ends.rs @@ -163,7 +163,8 @@ pub fn ends(kind: u8, data: &[u8], out: &mut Vec) { 2 => put(out, run.nth_back(usize::from(step >> 3) % 4)), 3 => out.push(run.len() as u8), 4 => put_hint(out, run.size_hint()), - 5 => put(out, (&mut run).rev().next()), + 5 if step & 8 == 0 => put(out, (&mut run).rev().next()), + 5 => put(out, (&mut run).next_back()), 6 => out.push((&mut run).len() as u8), _ => put(out, run.nth(usize::from(step >> 3) % 4)), } @@ -205,7 +206,19 @@ fn consumed + ExactSizeIterator>(mut it: I, pi 5 => out.extend(it.take(k).rev()), 6 => out.extend(it.step_by(k.max(1)).rev()), 7 => put(out, it.rposition(|b| b % 3 == 0).map(|i| i as u8)), - 8 => put(out, it.skip(k % 4).rfind(|b| b % 3 == 0)), + // `rfind` folds from the back, through each adaptor that reads the length as it starts. + 8 => put( + out, + match k % 4 { + 0 => it.skip(k / 4).rfind(|b| b % 3 == 0), + 1 => it.take(k / 4).rfind(|b| b % 3 == 0), + 2 => it + .enumerate() + .rfind(|&(i, b)| (i as u8 + b) % 3 == 0) + .map(|(i, b)| i as u8 ^ b), + _ => it.step_by(k / 4 + 1).rfind(|b| b % 3 == 0), + }, + ), 9 => put(out, it.rev().last()), 10 => out.extend(it.map(|b| b ^ 0x55).rev().take(k)), 11 => { diff --git a/ts/runtime/rt/iter.ts b/ts/runtime/rt/iter.ts index ce608998e..dd36adffc 100644 --- a/ts/runtime/rt/iter.ts +++ b/ts/runtime/rt/iter.ts @@ -2223,17 +2223,21 @@ class EnumerateIter extends Adaptor { return item === DONE ? DONE : [this.index + this.inner.len(), item]; } - /** std's: its iterator folded, counting each item as it goes, and from the back from its length. */ + /** + * std's: its iterator folded, counting each item as it goes, and from the back down from + * its length as the fold starts. + */ override folded(fold = false): Iter<[number, T]> { const inner = this.inner.folded(fold); - if (inner === this.inner) return this; const front = (): [number, T] | Done => { const item = inner.next(); return item === DONE ? DONE : [this.index++, item]; }; + let i: number | undefined; const back = (): [number, T] | Done => { + i ??= this.index + this.inner.len(); const item = inner.nextBack(); - return item === DONE ? DONE : [this.index + this.inner.len(), item]; + return item === DONE ? DONE : [--i, item]; }; return new Folded(front, back); } @@ -2743,7 +2747,6 @@ class SkipIter extends Adaptor { */ override folded(fold = false): Iter { const inner = this.inner.folded(fold); - if (inner === this.inner) return this; const front = (): T | Done => { if (this.n > 0) { const n = this.n; @@ -2837,26 +2840,29 @@ class TakeIter extends Adaptor { /** * std's: its iterator folded, counting each item it reads against the limit, and from - * the back, past what it holds beyond the limit by `nth_back`, folded without counting. + * the back, past what it holds beyond the limit by `nth_back` as the fold starts, + * folded without counting. */ override folded(): Iter { const inner = this.inner.folded(); - if (inner === this.inner) return this; const front = (): T | Done => { if (this.n === 0) return DONE; const item = inner.next(); if (item !== DONE) this.n--; return item; }; + let ended: boolean | undefined; const back = (): T | Done => { - if (this.n === 0) return DONE; - const len = this.inner.len(); - if (len > this.n) { - const item = this.inner.nthBack(len - this.n - 1, this.drop); - if (item === DONE) return DONE; - this.drop?.(item); + if (ended === undefined) { + ended = this.n === 0; + const len = ended ? 0 : this.inner.len(); + if (len > this.n) { + const item = this.inner.nthBack(len - this.n - 1, this.drop); + if (item === DONE) ended = true; + else this.drop?.(item); + } } - return inner.nextBack(); + return ended ? DONE : inner.nextBack(); }; return new Folded(front, back); } @@ -3138,6 +3144,17 @@ class StepByIter extends Adaptor { return foldBy(this, false, acc, f, release); } + /** std's `try_rfold`: the last item by `next_back`, then each step back by `nth_back`. */ + override folded(): Iter { + let first = true; + const back = (): T | Done => { + if (!first) return this.inner.nthBack(this.step, this.drop); + first = false; + return this.nextBack(); + }; + return new Folded(() => this.next(), back); + } + /** std's: the last item by `next_back`, then each step back by `nth_back`. */ override rfold(acc: A, f: (acc: A, item: T) => A, release?: () => void): A { let done: boolean; From 8e31614efe64593fb7428e9a5cf2abea12922a12 Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 05:06:35 -0800 Subject: [PATCH 5/6] chore(quest): plan folds from the back and a crate's own folds Co-Authored-By: Claude Opus 5.5 --- quest/m3/README.md | 1 + quest/m3/ts-iter-back-folds.md | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 quest/m3/ts-iter-back-folds.md diff --git a/quest/m3/README.md b/quest/m3/README.md index 5c3286027..2317cc76b 100644 --- a/quest/m3/README.md +++ b/quest/m3/README.md @@ -28,6 +28,7 @@ generic std gap is planned here even when moq never calls it. - [A deque's two slices](/quest/m3/ts-deque-slices.md) - `VecDeque::as_slices` and `{:?}` of a deque's `Iter`, `IterMut`, and `Drain` translate, split where std's are - [Comparing places](/quest/m3/ts-place-compares.md) - `a.iter_mut().eq(&mut b)` and its orderings compare the values places lend - [std::iter::zip](/quest/m3/ts-iter-zip.md) - the free `zip` translates as `Iterator::zip` does +- [Folds from the back, and a crate's own folds](/quest/m3/ts-iter-back-folds.md) - `rfold` and `try_rfold` translate, and so does a crate's iterator that overrides `fold` or `nth_back` - [std's sorts call their tests in std's order](/quest/m3/ts-sort-order.md) - `slice::sort` and a B-tree's `collect` call `lt` or `cmp` as std's driftsort does past 16 elements - [A B-tree's searches call Ord as std's do](/quest/m3/ts-btree-search-order.md) - a B-tree's lookups and inserts call a key's own `Ord` in std's order and number - [Rc and Arc of a slice](/quest/m3/ts-shared-slices.md) - `Rc<[T]>` and `Arc<[T]>` from a `Vec`, a slice, or an iterator translate diff --git a/quest/m3/ts-iter-back-folds.md b/quest/m3/ts-iter-back-folds.md new file mode 100644 index 000000000..f30c37d16 --- /dev/null +++ b/quest/m3/ts-iter-back-folds.md @@ -0,0 +1,30 @@ +# [M] Folds from the back, and a crate's own folds + +## Goal + +[rust2-ts](/ts/README.md) translates `DoubleEndedIterator::rfold` and `try_rfold` of any +iterator, and a crate's own iterator that overrides a provided method std's adaptors call +in place of `next` or `next_back`, such as `fold` or `nth_back`. Each runs where native's +does, as many times and in the same order, proven by differential tests against native +Rust. + +## Plan + +Found by [#436](https://github.com/moq-dev/rust2/pull/436), which translates a crate's own +`next_back`, `len`, and `size_hint`: + +- `rfold` and `try_rfold` are an "unsupported call" for every iterator, std's included. + The runtime already folds from the back inside its adaptors (`Iter.rfold`, `folded`), + so the gap may be mostly the mapping. +- A crate's own `Iterator::fold` or `DoubleEndedIterator::nth_back` is refused as + "overriding `_`, which std's adaptors call in place of `next` or beside it". Each override + is a method std's adaptors and consumers call in place of the default: `fold` from + `for_each`, `count`, `last`, and `Map::fold`, `nth_back` from `Rev::nth`. `rt.iterFrom` + would call it there, as it now calls `next_back`. +- Open: whether overrides of the other provided methods (`nth`, `try_fold`, `rfold`, + `advance_by`, `count`, `last`, and more) land here too. Each is the same problem, and + the runtime's callers of each decide how far it reaches. +- `lang`'s `ends` fixture logs each method a crate's iterator is called through, and can + extend to these. + +Public API: the translator's output. From 9e2f1b3e472228b6667ac4191297acfd2a90a9d9 Mon Sep 17 00:00:00 2001 From: Luke Curley <432854+kixelated@users.noreply.github.com> Date: Mon, 2 Nov 2026 14:00:43 -0800 Subject: [PATCH 6/6] chore(quest): size ts-model now its last child finishes Co-Authored-By: Claude Opus 5.5 --- quest/m2/ts-model/README.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/quest/m2/ts-model/README.md b/quest/m2/ts-model/README.md index 14abed2f4..e1cebbcff 100644 --- a/quest/m2/ts-model/README.md +++ b/quest/m2/ts-model/README.md @@ -1,4 +1,4 @@ -# Translate moq-net's model to TypeScript +# [L] Translate moq-net's model to TypeScript ## Goal @@ -29,7 +29,7 @@ Decided with the maintainer on 2026-10-27, from a census of the model's 22 publi `cache::Pool`, `listing::Tracks`, `time::Timestamp`): 4,595 refusals over 1,112 items. 2,588 are calls into the workspace crates, and 424 items refuse nothing else. -- This is an epic; each group of refusals is a child below. moq must work, but nothing in +- Each group of refusals is its own quest. moq must work, but nothing in the translator is specific to moq: dependencies follow general rules, and moq's own changes (safe `cfg` twins of its `unsafe`, dropping or binding `hashlink`, `slab`, and `smallvec`) are one research-tier quest in moq's tree. @@ -46,6 +46,3 @@ Decided with the maintainer on 2026-10-27, from a census of the model's 22 publi `frames.ts` workload. moq writes the binding files `model.toml` names, in its own tree. Public API: the translator's output for moq-net's model. - -## Required -