052 pattern branches

✓ Passing This code compiles and runs correctly.

Code

input.kz

Must contain:

no branch 'GET /users/:id'

Error Verification

Expected Error Pattern

Pattern branches without a transform produce KORU021 errors.

This test verifies that pattern branch SYNTAX parses correctly.
The validation correctly rejects unknown branches like [GET /users/:id]
when the event only declares 'ok'.

Expected errors:
  - KORU021: unknown branch '[GET /users/:id]'
  - KORU021: unknown branch '[POST /users]'
  - etc.

Actual Compiler Output

error[KORU021]: event 'input:test-patterns' has no branch 'GET /users/:id' (available: (none))
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/input.kz:19:0

error[KORU021]: event 'input:test-patterns' has no branch 'POST /users' (available: (none))
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/input.kz:19:0

error[KORU021]: event 'input:test-patterns' has no branch 'nested [brackets] work' (available: (none))
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/input.kz:19:0

error[KORU021]: event 'input:test-patterns' has no branch '* -> stopped' (available: (none))
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/input.kz:19:0

❌ Compiler coordination error: Incomplete branch coverage
error: CompilerCoordinationFailed
/Users/larsde/src/koru/tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/backend.zig:94:13: 0x10244b38b in emit (backend)
            return error.CompilerCoordinationFailed;
            ^
/Users/larsde/src/koru/tests/regression/200_COMPILER_FEATURES/210_PARSER/210_052_pattern_branches/backend.zig:190:28: 0x10244c077 in main (backend)
    const generated_code = try RuntimeEmitter.emit(compile_allocator, final_ast);
                           ^

Test Configuration

MUST_FAIL