✓
Passing This code compiles and runs correctly.
Code
// Test: Parser should reject empty braces {} in branch payloads
// Empty braces are meaningless - use void events (no branches) or identity syntax instead
const std = @import("std");
// WRONG: Empty braces in branch payload
// Should be either:
// - A void event: ~event done {} (no branches at all)
// - Identity syntax: | done SomeType
~event verify {}
| ok {}
Expected
error[PARSE003]: empty braces in branch payload - remove braces for void branch or use identity syntax '| ok Type'
--> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_062_reject_empty_brace_payload/input.kz:11:4
|
11 | | ok {}
| ^
Test Configuration
Expected Behavior:
FRONTEND_COMPILE_ERRORExpected Error:
empty braces