honesty: CI example gate, audit verify-rhs, wasm-gc string scalars and Result equality#499
Merged
Conversation
…n wasm-gc string and Result-equality semantics with the VM Four fixes from the 0.25.0 release lessons: - CI gates the example corpus: the Check & Test job now runs aver check over examples/core and examples/data on bare exit codes — a broken shipped example can no longer ride a green pipeline. - aver audit counts error[verify-rhs]: the check-error filter excluded every verify-* slug to avoid double-counting verify execution failures, swallowing this static check error entirely; the filter now keys on severity. - wasm-gc strings use the VM's character index space: String.len counts Unicode scalars (String.byteLength keeps bytes as its own builtin), charAt returns whole characters at scalar indices, slice and chars mirror the runtime exactly. A len-only fix measurably made things worse — the whole index family had to move together. examples/data/json.av and grok_s_language.av now verify on wasm-gc with summaries identical to the VM. String.len is now O(n); doom grows 166 bytes, the other six games are byte-identical. - Result equality no longer traps when two record types in one module carry their own Result<Record, String>: the constructor resolver ignored the expression's stamped type and matched the first registered instantiation by payload position; it now resolves via the stamped type first. Known residuals stay documented: Char.toCode is still byte-based on wasm-gc, and tuples of two differently-typed Results are rejected by the verify typechecker (both pre-existing). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The four follow-ups from the 0.25.0 release lessons (two tooling holes that let a broken corpus ride green CI, and the two cross-target divergences the release documented as residuals):
examples/core+examples/data(bare exit codes, new step in Check & Test;examples/diagnosticsstays deliberately ungated)aver auditcountserror[verify-rhs]— the filter excluded everyverify-*slug to avoid double-counting execution failures, swallowing this static error; now keyed on severity0 errors/exit 0→1 error/exit 1; no double-count of genuine verify failuresString.lencounts scalars,charAt/slice/charsfollow,String.byteLengthsplit off keeping bytes. A len-only fix measurably made json.av worse (1→5 failures), so the family moved togetherjson.avverify --wasm-gc: 400/403 +1 fail → identical summary to VM (402/403); bonus:grok_s_language.av90/105 → 101/105, VM parity. Perf: len O(n); doom +166 B, six games byte-identicalResult<Record, String>instantiations in one module — constructor resolution ignored the stamped type and took the first payload-position match; the eq helper then cast the wrong heap typeorder_total.av→ 55/55 exit 010 new regression tests (each revert-tested red); full corpus proof exports byte-identical (88/88); proof_spec 145/145; workspace tests with wasm features green; clippy ×3 gates clean.
Known residuals documented in the commit:
Char.toCodestill byte-based on wasm-gc;Tuple<Result<A,_>, Result<B,_>>equality rejected by the verify typechecker (both pre-existing).CHANGELOG: new
## 0.25.1 (unreleased)section; 0.25.0 untouched.🤖 Generated with Claude Code