Repository navigation
VBD decision 47 step 2, Generation A: bindings are immutable unless declared mut(name) (locals, patterns, comptime) - #1440
Merged
Merged
Conversation
shd101wyy
added a commit
that referenced
this pull request
Oct 17, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…on, E0917 for locals, census knob, yo fix --migrate mut-bindings Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 17, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e fixture Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…pture tests typed Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… parameters; the migration holds writes inside comptime_expect_error until the case's outcome; module-level mut(x) :: accepted; std/time receivers and Array.len take &Self; scripts/ and build.yo exempt; registry examples Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Mechanical output of the decision 47 step 2 migration, regenerated with the final binary rather than merged by hand on a rebase: yo fix <every tests/ .yo outside cli-cases and internal> --migrate mut-bindings, then one file at a time for the 49 files the multi-file run could not evaluate (issues/2026-10-15-yo-fix-over-several-files-...), then tests/internal, then the negative/verify fixtures by their E0917 notes. 2117 + 243 + 10 bindings marked; 9 parameter writes listed (rebound by hand in the next commit). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ts by hand; the in-place insertion-sort spec takes s : &mut Array (same 16 obligations proved) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… &mut capture of a parameter is E0917 first Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
22 cases: only the fixture hash moved (written locals declared mut; rc and stdout unchanged). fix-migrate-explicit-copy: marked fixture, a listed site's column moves 27:9 -> 27:14. explain-list: E0917's title is now 'a write to an immutable binding'. fix-migrate-borrow-spelling: the case runs mut-bindings in phase order (one more fix line). fix-migrate-mut-bindings: new. init*, skills-install*, build-stamp-dotted-dir: the syntax cheatsheet changed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nded entry Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
force-pushed
the
feat/vbd-d47-locals-gena
branch
from
October 17, 2026 23:58
41118ff to
fcd9eaa
Compare
…igrate mut-bindings) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…to the end of VBD; refresh branch resume points - VALUES_BY_DEFAULT: decision 21 amended (Rc by sharing, Box when built once); §9 lists the decided questions; decision 47 step 2 records #1440's two accepted departures - PARALLELISM_RULES D9: recommend a capture-free closure for a named function until function-item types land - handover: §3.4 verdicts, §4 rewritten as the ordered path to finishing VBD, §2.4 resume points after the WSL crash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…known issues; D9 names the plain-local closure Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…heatsheet hash, marked fixture); file the env-size-dependent OOM case (S3) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…to the end of VBD; refresh branch resume points - VALUES_BY_DEFAULT: decision 21 amended (Rc by sharing, Box when built once); §9 lists the decided questions; decision 47 step 2 records #1440's two accepted departures - PARALLELISM_RULES D9: recommend a capture-free closure for a named function until function-item types land - handover: §3.4 verdicts, §4 rewritten as the ordered path to finishing VBD, §2.4 resume points after the WSL crash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…known issues; D9 names the plain-local closure Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
… battery 39087983359 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3 of 6 tasks
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…with the seed); #1441 fixes it; the lesson in §1.1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…a mut-bindings pass after rebasing onto #1440 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…grate mutable-globals); its 4 site-list handle globals reset in place Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…d compile.test.yo's embedded fixture (E0917 since #1440) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…; two probes and one fixture mark their locals (#1441) * fix(develop): the FV job runs its tests/internal verifier files on stage 1, not the seed (#1440's mut(x) := is unparseable to v0.2.64) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(develop): mark the written locals in the musl and epoll probes and compile.test.yo's embedded fixture (E0917 since #1440) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…to the end of VBD; refresh branch resume points - VALUES_BY_DEFAULT: decision 21 amended (Rc by sharing, Box when built once); §9 lists the decided questions; decision 47 step 2 records #1440's two accepted departures - PARALLELISM_RULES D9: recommend a capture-free closure for a named function until function-item types land - handover: §3.4 verdicts, §4 rewritten as the ordered path to finishing VBD, §2.4 resume points after the WSL crash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…known issues; D9 names the plain-local closure Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
… battery 39087983359 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…with the seed); #1441 fixes it; the lesson in §1.1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…a mut-bindings pass after rebasing onto #1440 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…7 heads); std stays unmarked until its sweep Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…to the end of VBD; refresh branch resume points - VALUES_BY_DEFAULT: decision 21 amended (Rc by sharing, Box when built once); §9 lists the decided questions; decision 47 step 2 records #1440's two accepted departures - PARALLELISM_RULES D9: recommend a capture-free closure for a named function until function-item types land - handover: §3.4 verdicts, §4 rewritten as the ordered path to finishing VBD, §2.4 resume points after the WSL crash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…known issues; D9 names the plain-local closure Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
… battery 39087983359 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…with the seed); #1441 fixes it; the lesson in §1.1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…a mut-bindings pass after rebasing onto #1440 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…7 heads); std stays unmarked until its sweep Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
* docs(handover): VBD handover 2026-10-17 (living until v0.2.65) The v0.2.65 gate, every open PR and pushed branch with what is left, #1408's verdicts, the recursive E0916 structural-clone exemption, the open S1s and the portable process rules learned this cycle. The plan, the plans index and the 2026-10-15 handover point here. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): pin head SHAs, add the stale-doc safeguard, the stop sequence and a v0.2.65 notes draft Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(plans): the index lists only the current VBD handover Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(plans): drop the v0.2.51 release handover from the index Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1435 landed; d47loc and #1432 heads Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): status checks every 50 minutes Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs: 40-minute cache-warm pings for background sub-agents (AGENTS.md, handover) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1412 landed; #1421 head Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): derive Clone PR B is #1437 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1438 landed (v0.2.65 gate item 3); notes draft Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1409 landed; its two new issues; #1421 head Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs: #1432 landed (handover; plan cites #1432 instead of the deleted branch); A4's S1 as a known issue Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): Pattern is #1439, Generation B after the v0.2.65 seed Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): no rebase after the final gate; SHAs from git output; #1437 head Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1424 and #1420 landed; #1424's new issues Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1439 state and post-seed steps; #1433 landed Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1437 landed; its open S2 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1419 landed Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): MERGE_FREEZE for v0.2.65; decision 47 locals is #1440 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1414 Tier 1 green, held by the freeze Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1429 landed (v0.2.65 gate item 2) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1429's user-visible changes and maintainer questions Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(issues): retire the three VBD questions decided 2026-10-18; file the two projection-forwarding gaps (S2 ref receiver, S3 bare-tail E0601) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): record the 2026-10-18 verdicts; roadmap from v0.2.65 to the end of VBD; refresh branch resume points - VALUES_BY_DEFAULT: decision 21 amended (Rc by sharing, Box when built once); §9 lists the decided questions; decision 47 step 2 records #1440's two accepted departures - PARALLELISM_RULES D9: recommend a capture-free closure for a named function until function-item types land - handover: §3.4 verdicts, §4 rewritten as the ordered path to finishing VBD, §2.4 resume points after the WSL crash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): v0.2.65 notes draft names #1440's surface and the Q5 known issues; D9 names the plain-local closure Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1440 merged (00eddd3); v0.2.65 gate waits on develop battery 39087983359 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): develop red after #1440 (FV job ran Gen A test files with the seed); #1441 fixes it; the lesson in §1.1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): final v0.2.65 release-notes text; held branches need a mut-bindings pass after rebasing onto #1440 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1441 merged (e34b6b0); the v0.2.65 gate waits on develop battery 39099399553 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): the four held branches re-gated on #1440 (wip/*-on-d47 heads); std stays unmarked until its sweep Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): v0.2.65 gate met (battery 39099399553 green on e34b6b0); Release run 39106358669 dispatched Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): #1442 joins the post-release stop sequence Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): ci/fmt-check-plans joins the post-release sequence (after #1442) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(handover): final — v0.2.65 published, #1442 and #1443 merged, freeze removed, nothing running Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…rc/std/scripts/build.yo); only the globals rules leave it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…ls rule's exemption) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…grate mutable-globals); its 4 site-list handle globals reset in place Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…a nested comptime_expect_error keeps the outer one's mode (#1436) * fix(evaluator): a write into a `&T` parameter's value is E0908 (S2); a nested comptime_expect_error keeps the outer one's mode Rebased onto develop e7e348c (squash replay of the branch's 21 commits; import-list conflicts in assignment.yo and initialization_assignment.yo resolved as the union of develop's #1440 imports and this branch's). * chore(tests): the mut-bindings migration output for decision 47's locals rule yo fix --migrate mut-bindings (tree binary) on this branch's changed test files: 2 marks (fwb_scratch's owned copy; the x lent &mut to _through_mut). 4 parameter writes listed for hand rebinding follow in the next commit. * test: rebind _own's by-value parameter writes onto a mut local The migration lists the four writes of the by-value parameter p (its fields, element and &mut self receiver): a parameter takes no mut, so the body rebinds it (mut(q) := p) and writes the owned copy, as tests/mut_bindings.test.yo teaches.
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…rc/std/scripts/build.yo); only the globals rules leave it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…ls rule's exemption) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…grate mutable-globals); its 4 site-list handle globals reset in place Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…rc/std/scripts/build.yo); only the globals rules leave it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…ls rule's exemption) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…grate mutable-globals); its 4 site-list handle globals reset in place Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 18, 2026
…tion is gone, E0909 narrowed to mut globals (waits for the v0.2.64 seed) (#1414) * WIP: decision 47 globals Gen B — reset the 60 reassigned handle globals in place (clear / split_off / append); docs drop the Generation A exemption Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * WIP: drop is_global_mut_rule_exempt; E0909 for a global lent to a borrowing future only on mut(G)/thread_local(mut(x)) roots; markdown_yo pinned to the companion branch Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * WIP: yo fix ./std --migrate mutable-globals (12 globals) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * WIP: yo fix ./src --migrate mutable-globals (189 globals) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * WIP: rewrite the 88 E0916 lends of mut globals (copy out, write back) and the 3 rule-A conflicts in std/src Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * plans: decision 47 globals Generation B as built; handover §2.3/§4/§5.1; question doc on reading a non-Copy mut global under unique buffers Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * E0916's hint copies out with `v := G` (`G.clone()` is itself a lend of a mut global); census attribution Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * deps: markdown_yo pinned to the merged companion (9bfd5c1e2, shd101wyy/markdown_yo#19) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * issues/questions: the non-Copy mut-global read is decided (option 1, recursive structural-clone exemption), awaiting implementation in V2b B1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * deps: markdown_yo ^0.0.18 (the release carrying the decision 47 companion, shd101wyy/markdown_yo#19) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * rebase onto #1440: the locals rule keeps is_global_mut_rule_exempt (src/std/scripts/build.yo); only the globals rules leave it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * rebase onto #1440: keep exporting is_global_mut_rule_exempt (the locals rule's exemption) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * cli-case comment: no tree is exempt from the globals rules after Generation B Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * rebase onto #1440: mark the 2 value globals #1440 writes (yo fix --migrate mutable-globals); its 4 site-list handle globals reset in place Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
shd101wyy
added a commit
that referenced
this pull request
Oct 19, 2026
…1440 `cur.insert(..)` is an exclusive call on the local, so decision 47 step 2 needs `mut(cur)`. The goldens are re-recorded with the tree binary in the same PR. Generated by `yo fix --migrate mut-bindings` (VBD handover 2026-10-17 §4.1). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
9 tasks done
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.
Summary
This is decision 47 step 2 (locals, patterns and comptime), Generation A (
plans/VALUES_BY_DEFAULT.md§6, "Decision 47: immutable bindings"). Every binding below module level is now immutable unless its name is wrapped inmut(...), like Rust'slet mut.The marker in every binding position:
mut(x) := v,(mut(x) : T) = v,(mut(x) : T);mut(x) :: vandcomptime(mut(x)) := v.Some(mut(v))and(mut(w) := p)in amatchpattern{ a, mut(b) },{ x : mut(b) }and(a, mut(b))in a destructuringmut(x) : Ton a parameter stays E0009. The evaluator strips the marker in place and records it against the declared name's token (register_mut_binding).E0917 (renamed
E_IMMUTABLE_BINDING_WRITE) for the four writes to an unmarked binding:(x : T);declaration, on each branch, is its initialization);Arrayelement write to the binding's own storage;&mutlend: a&mut xargument, a&mut selfreceiver,y := &mut x,match(&mut x, …)or a&mut xcapture;&mut selfmethod call.A
refhandle (today's collections,ref(struct)) is written through without the marker, but reassigning one needs it.Stringis a value, sos.push_str(..)needsmut(s).Bindings that rebind instead: parameters, capture-list entries and
forelement bindings take nomut. A write to one is E0917 with a "rebind it" help (mut(p_m) := p;, a move). For aforelement, the help suggestsfor(&mut coll, x => …)instead. Reassigning a parameter stays E0902.E0918 is unchanged and checked first, so a runtime write to a
mut(x) ::binding is still E0918.Scope: the rule is enforced outside
src/,std/, the repository'sscripts/andbuild.yo, through the globals step's exemption (is_global_mut_rule_exempt), because the released seed still builds those trees.Census knob:
YO_AUDIT_MUT_BINDINGS=1prints every write ([mut-binding] how=… kind=… marked=…) without rejecting it.Migration:
yo fix <path> --migrate mut-bindingsinserts the markers and lists the parameter, capture-list andfor-element writes to rebind by hand.comptime_expect_errorargument until the case's outcome is known.The tests/ sweep is that tool's output in its own regenerable commit (
be581a2b9), followed by a separate commit of hand rebinds.Docs and registry:
.github/instructionsand the syntax cheatsheet;Deviations and behavior changes that need the maintainer's eye
mut(x) :: vis accepted. This goes against the plan's open-point recommendation (block scope only). The reason:tests/comptime.test.yoalready reassigns a module-level::binding at module level (_RW_M = i32(2);). Rejecting that would delete a working feature, which is beyond a Generation A; Generation A only asks for the marker. Whether module level keepsmut(x) ::is the maintainer's call, and rejecting it later is a one-line error.std/time(Duration.as_secs,Instant.elapsed,DateTime.to_unix, …) and the prelude'sArray(T, N).lentookself : &mut Selfand now takeself : &Self. With the old signatures,d.as_secs()on an unmarkedDurationwould be E0917 under this rule. Filed asissues/fixed/2026-10-17-std-time-read-only-methods-take-self-mut.md(S2), with a test that fails before the fix.yo docoutput for these methods changes.&mutcapture of a by-value parameter used to be rejected with "A&mutcapture needs a writable place". A parameter is now an immutable binding, so E0917 ("Cannot lend&mut(a&mutcapture)x: it is a parameter…") fires first.tests/closure_capture_list.test.yonow expects that text.Ordering
The src/std sweep (Generation B) comes after V2b Generation B. Once the collections are values, their handle writes also need the marker: about 5,800 in src, 480 in std and 2,100 in tests.
Generation A does not depend on V2b:
mut(parsed by a released seed one release earlier.One obligation passes to V2b Generation B. The marker strip edits a call's argument list in place, which works only because
ArrayListis a shared handle today. WhenArrayListbecomes a value, the strip must write the edited list back.Verification
Re-gate after the rebase onto develop
29ceb209d(#1429, #1419, #1437, #1433, #1424). The numbers in the rest of this section are from the earlier baseb94fd6968unless marked post-rebase.Post-rebase build: tree
yo build --std-path ./std(seed v0.2.64) rc=0;check ./src278/278; treecheck ./std172/172.Post-rebase migration:
yo fix --migrate mut-bindingsover the 22 test files develop changed sinceb94fd6968marked 108 bindings in 12 of them. They are committed separately and contain onlymut(...)binding marks.Post-rebase tests (tree binary,
YO_TEST_LEAK_VERDICT=0, one file per call,--parallel 1 --std-path ./std): every file rc=0.Post-rebase cli-diff (full run, tree binary): 399 PASS, 8 GOLDEN-DIFF, 1 NO-GOLDEN, 1 SKIP (network).
build-stamp-dotted-dir,init,init-build-test,init-cwd,init-existing,skills-install,skills-install-zh) andcheck-strict-borrow-loop-calls-a-read-only-method, whose fixture hash moved because of itsmutmarks. In every case only anexpected_treehash line moved; rc and stdout are unchanged. All 8 were re-recorded with the tree binary and re-run: PASS 8.compile-allocator-fixed-oom, comes from the environment and also happens on develop. The probe's PARENT runs in the 64 KiB fixed heap, and it exhausts that heap when the caller's environment is about 2 KB larger than this shell's 34 KB. The largest passing pad is 27,187 bytes for develop's probe and 27,347 bytes for this branch's. With three large shell variables unset, the case PASSes. Filed asissues/2026-10-18-compile-allocator-fixed-oom-case-fails-under-a-large-caller-environment.md(S3).Post-rebase fmt and refs: tree
fmt --check ./std ./tests ./src ./docs ./.github ./README.md(GATE 6) passes, andscripts/check-issue-refs.shis green.Pre-rebase gate (base
b94fd6968):Tree-built compiler,
yo build --std-path ./stdwith seed v0.2.64: rc=0.yo check ./src --std-path ./std(seed): 278/278.yo check ./std --std-path ./std(tree binary): 172/172.Full language suite (
yo test ./tests --exclude tests/internal --exclude tests/cli-cases --parallel 4): 5274 passed, 43 failed.closure_capture_list(the diagnostic-order change above). After the expected-text fix, that file reruns at 41/41.tests/os/env.test.yo"temp_dir returns /tmp on Linux" (the shell setsTMPDIR=/tmp/nix-shell.…);tests/time/datetime.test.yo"DateTime.now honours TZ: Asia/Tokyo" (no TZ data).tests/mut_bindings.test.yo(new, 13 tests) covers the four writes accepted and rejected, ref handles, typed declarations, first-assignment initialization, patterns, destructuring, comptime, E0918, parameter rebinds (and the move),&mutscrutinee and capture, read-only std receivers, and module-levelmut ::.tests/internal, in-process (
YO_TEST_IN_PROCESS=1, one run): 108 passed, 1311 failed, every failure leak-only, 0 non-leak failures. This is the same 108/1311 as d46's run on its own branch, and the same in-process leak artifact; check_watch has 12 leak-only failures on both sides. Each top file run alone with identical flags, develop (yo-dev-5425cd7bf, its tree) against this branch:The same tests leak on both sides: one each in types_utils ("raw-ptr predicate: a type object that contains itself terminates"), verifier_list_len, and error ("warnings: the stash dedupes…"), plus all 12 of check_watch's tests.
cli-diff: after re-recording, 399 PASS, 0 GOLDEN-DIFF, 0 NO-GOLDEN, 1 SKIP (network). Every changed golden, and why:
mut). Only the fixture hash inexpected_treemoved; rc and stdout are unchanged:mut(was inserted on that line.--migrate mut-bindingsafter borrow-spelling, in phase order. That adds onefix:line and changes the output tree.check, which reports E0917 for a parameter write the tool lists but does not rewrite.Census with the final binary,
YO_AUDIT_MUT_BINDINGS=1:fmt: tree binary
fmt --checkpasses on every changed.yoand.mdfile.scripts/check-issue-refs.shis green.LLM attribution
Deferred
markdown_yoand enforce everywhere, after V2b Generation B. The plan's census table sizes it.cur = &mut n.next) withoutmut(cur)is not checked yet. Themut(cur) := &mut placedesugar comes with decision 43.mut(x) ::(above).scripts/build_site.yo(25 bindings, 8 parameter writes) is built by the seed in release.yml, soscripts/is exempt like src/std until Generation B.yo fixover several files still fails to evaluate some files (issues/2026-10-15-yo-fix-over-several-files-applies-one-files-generic-impls-to-anothers-same-named-type.md, S3). The sweep migrated those files one at a time.🤖 Generated with Claude Code