agent: builder model: sonnet max_turns: 50 budget_usd: 8 —

Brief: commit the built fix for #893 (Fixes #893)

Score: bugs lane (docs/priorities.md, bugs-first default). The b893 builder built and tested the fix but did not commit: the gate was red from range_spelling (fixed by the brief before this one).

Issue text (#893)

let s: String? = if b != null { b } else { c } passes nikaia check, rustc Mismatched types. Fix: check_core_stmt_owns_whole holds for T? when it holds for T, so a let/assignment at a T? place takes return’s path (narrowed_reads_given_back, ADR-382).

The work is in the checkout (uncommitted)

crates/nikaia-std/src/tools/check_core_stmt.nika, crates/nikaia-std/src/tools/lowered/check_core_stmt.rs, tests/compiler/tests/a_proved_arm_bound_at_an_optional_let.nika + .stdout. Read the diff; do not rebuild it. Previous report: docs/briefs/b893-optional-let-proved-arm.md.report.md.

To build

  1. Check git log -1 holds the range_spelling fix. Build, rerun the tests below, run the gate; if green, commit exactly these four files and push. If lower-std rewrites another lowered/*.rs, leave it out and say so in Body:.

Done when

nikaia test --both-settings --project tests/compiler; it -- narrow nullable handed_over; the gate; clippy clean. Commit subject: check: a proved arm bound at a T? let or assignment is given up (#893), Fixes: #893. Changelog: A proved name at an arm tail of a value bound by a let or an assignment at a T? place is given up and the choice wrapped in Some(..), as return already did, instead of a borrowed &T that rustc refused (#893).

Stop and report if

The gate is red from a file not among the four; the diff is not as described.

Read docs/builder-facts.md.

Rules (CLAUDE.md; this block is pasted into every brief, also a fix-forward)

Report (at most 15 lines, to exactly /home/user/Nikaia/docs/briefs/b893-commit.md.report.md)

Fields of docs/architect.md, Briefs and reports: Result: done|noop|partial|blocked (the bare word alone on that line: Result: done, never a summary after it, which cuts the batch, b869a 2026-10-27; Owner: is a question for the owner or none, never a role), Files, Commit, Body (optional, one paragraph for the commit message), Fixes, Pushed, Tests, Gate (green|red), Deviation, Found, Needs, Changelog, Owner, Disk freed, and for a move Rs2nika: (the kept N of M lines of rs2nika --score, then the three costliest hand edits; none for a task that moves no Rust). none where nothing, and then the bare word: Deviation: none (a note) cuts the batch (batch.nika compares exactly); a note goes into the commit message. Found: is only for a defect outside your change (it cuts the batch); how you solved your own step goes into the commit message. Deviation: is only a step of the brief built otherwise than written or not built (a choice the brief left to you, such as keep what X needs and say so, is no deviation: it goes into the commit message; nor is building two steps in one commit when every step is built, e12-3a 2026-10-27: say so in Body:); how you verified (e.g. a test not run against the unfixed compiler) goes under Tests:. A noop says why under Tests: (what was probed), not under Deviation:. Final answer, one line: done <sha>, report <path> (or BLOCKED: ... / PUSH REJECTED ...).

Attribution: Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com Claude-Session: https://claude.ai/code/session_01GFeMqxRbtUMiGVyDMxsvEq

This site is open source. Improve this page.