Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion quest/m2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ The fork's feature quests folded into the [exporter](/quest/m1/ffi-export.md);
## Required

- [Byte slices without objects](/quest/m2/ts-byte-views.md) - splitting a `&[u8]` allocates nothing, neither a chunk view nor a `ByteSlice`
- [Smaller output from MIR](/quest/m2/ts-mir-size.md) - the codec bundle shrinks back to THIR's gzipped size
- [An A/A control that measures noise](/quest/m2/ts-bench-aa.md) - `just ts bench`'s A/A measures only noise, in every engine
- [Time Timestamp's checked_add and Ord](/quest/m2/ts-bench-timestamp.md) - the `u128` paths #89 sped up get a Chrome timing
- [Drop in the TypeScript translator](/quest/m2/ts-drop.md) - every value that drops in moq-net and kio drops where Rust drops it
Expand Down
54 changes: 0 additions & 54 deletions quest/m2/ts-mir-size.md

This file was deleted.

5 changes: 2 additions & 3 deletions ts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -298,9 +298,8 @@ they need.
the coroutine transform's state machines, a class each. Against the THIR lowering it
replaced, MIR closes about 1,100 of the 1,400 drop refusals in moq-net's census, and
runs `just ts bench`'s codec 2-6% faster at the geometric mean and the async handoff
1.4-5.9x faster at depths 1 to 16 in Node, Bun, and Chrome, for 1% more gzip on the
codec's bundle and 9% on the async fixture's
([size](/quest/m2/ts-mir-size.md)). Blocks become nested blocks, loops, and `if`s by
1.4-5.9x faster at depths 1 to 16 in Node, Bun, and Chrome, in bundles no larger
gzipped. Blocks become nested blocks, loops, and `if`s by
Ramsey's "Beyond Relooper", except a coroutine's resume function, which enters loops
in the middle and becomes a loop over a `switch` on the next block. Temporaries
assigned once and read once fold back into the expression that reads them unless that
Expand Down
7 changes: 4 additions & 3 deletions ts/runtime/rt/collections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import { panic } from "../rt.ts";
import { type Limbs, lt } from "./int.ts";
import { DONE, type Done, Iter, iterToArray, RangeInclusive } from "./iter.ts";
import { DONE, type Done, Iter, iterToArray, type RangeInclusive } from "./iter.ts";
import { type Arc, dropAll } from "./task.ts";

// Ordering
Expand Down Expand Up @@ -1227,8 +1227,9 @@ export type Bounds<K> = { readonly start: K; readonly end: K } | RangeInclusive<
/** `RangeBounds`: the start, the end, and whether the end is in the range. */
function bounds<K>(r: Bounds<K>): [{ key: K } | undefined, { key: K } | undefined, boolean] {
if (r === undefined) return [undefined, undefined, false];
// Exhausted, an inclusive range ends before its end, as its `end_bound` says.
if (r instanceof RangeInclusive) return [{ key: r.lo }, { key: r.hi }, !r.exhausted];
// Exhausted, an inclusive range ends before its end, as its `end_bound` says. A field
// test, not `instanceof`, so a bundle without `a..=b` leaves the class out.
if ("exhausted" in r) return [{ key: r.lo }, { key: r.hi }, !r.exhausted];
return ["start" in r ? { key: r.start } : undefined, "end" in r ? { key: r.end } : undefined, false];
}

Expand Down
Loading