006 store reject watch body ambient context

✓ Passing This code compiles and runs correctly.

Code

input.kz

Backend must reject with:

CONTAINS watch body
CONTAINS ctx
CONTAINS write sites

Error Verification

Actual Compiler Output

🎯 Compiler coordination: Passes: 15 (flow-based: frontend, analysis, emission)
Error: output_emitted.zig:70:20: error: std/store: watch body references 'ctx', runtime state of the enclosing flow - a watch body executes at 'game's write sites, not here; bind it through a store or react at a write site
        comptime { @compileError("std/store: watch body references 'ctx', runtime state of the enclosing flow - a watch body executes at 'game's write sites, not here; bind it through a store or react at a write site"); }
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
referenced by:
    main: output_emitted.zig:716:22
    callMain [inlined]: /opt/homebrew/Cellar/zig/0.15.2_1/lib/zig/std/start.zig:618:22
    callMainWithArgs [inlined]: /opt/homebrew/Cellar/zig/0.15.2_1/lib/zig/std/start.zig:587:20
    main: /opt/homebrew/Cellar/zig/0.15.2_1/lib/zig/std/start.zig:602:28
    1 reference(s) hidden; use '-freference-trace=5' to see all references

Flows

flow ~create click a branch to expand · @labels scroll to their anchor
create (expr: game, source: entities: 0[i64])
flow ~setup click a branch to expand · @labels scroll to their anchor
setup

Test Configuration

MUST_FAIL

Expected Error:

watch body references 'ctx', runtime state of the enclosing flow — a watch body executes at 'game's write sites, not here; bind it through a store or react at a write site