✓
Passing This code compiles and runs correctly.
Code
// "Never nest `!`": an indented `!` under an effect branch is not a resume
// arm and not legal anywhere — effect composition lives in the flat `|` arm
// list, never in nested effects. Sibling of the accept pins 210_092/093.
~pub event request { payload: i32 }
! ask i32
! nested i32
| timeout
| done i32
~proc request|zig {
const r = ask(payload);
return .{ .done = r };
}
Frontend must reject with:
CONTAINS effect branches never nestError Verification
Actual Compiler Output
error[PARSE003]: effect branches never nest - composition lives in the '|' resume arms
--> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_136_effect_arms_never_nest_effects/input.kz:6:1
|
6 | ! nested i32
| ^Test Configuration
MUST_FAIL