020 label jump obligation

✓ Passing This code compiles and runs correctly.

Code

input.kz

Must contain:

Phantom state mismatch

Error Verification

Actual Compiler Output

error[KORU030]: Phantom state mismatch: argument 'res' has no tracked phantom state, but event requires '<open>'. The value must be in state 'input:open'.
  --> phantom_semantic_check:51:0

error[KORU030]: Phantom state mismatch: argument 'res' has no tracked phantom state, but event requires '<!open>' (consumption). Did you mean to pass a value with state 'input:open'?
  --> phantom_semantic_check:51:0

error[KORU030]: Label jump '@loop' drops cleanup obligation for 'c' - pass it as an argument or discharge it before jumping
  --> phantom_semantic_check:51:0

❌ Compiler coordination error: Phantom semantic validation failed
error: CompilerCoordinationFailed
/Users/larsde/src/koru/tests/regression/300_ADVANCED_FEATURES/370_PHANTOM_TYPES/370_020_label_jump_obligation/backend.zig:94:13: 0x100fdb38b in emit (backend)
            return error.CompilerCoordinationFailed;
            ^
/Users/larsde/src/koru/tests/regression/300_ADVANCED_FEATURES/370_PHANTOM_TYPES/370_020_label_jump_obligation/backend.zig:190:28: 0x100fdc077 in main (backend)
    const generated_code = try RuntimeEmitter.emit(compile_allocator, final_ast);
                           ^

Test Configuration

MUST_FAIL