✓
Passing This code compiles and runs correctly.
Code
// A payload-less effect branch is spelled by OMISSION — `! ask | halved i32
// | timeout` — never with a unit token. `()` is not a type in the decl
// grammar; without this wall it parses as an identity payload whose type
// string is literally "()" and dies three stages later as a misleading
// KORU030. The unit exists only on the VALUE side: the proc calls `ask()`
// positionally. (Ruled 2026-07-01: omission is the one spelling; no synonym.)
~pub event request { payload: i32 }
! ask () | halved i32 | timeout
| done i32
~proc request|zig {
const r = ask();
return switch (r) {
.halved => |v| .{ .done = v },
.timeout => .{ .done = -1 },
};
}
Frontend must reject with:
CONTAINS spelled by omissionError Verification
Actual Compiler Output
error[PARSE003]: '()' is not a payload type - an empty payload is spelled by omission (write `! ask`; resume arms may follow: `! ask | ok i32 | fail`)
--> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_137_effect_unit_payload_spelled_by_omission/input.kz:8:1
|
8 | ! ask () | halved i32 | timeout
| ^Test Configuration
MUST_FAIL