020 instance ambiguous discharge

✗ Failing This test is currently failing.

Failed: wrong-error

Failure Output

Showing last 10 of 11 lines
  --> phantom_semantic_check:17:0

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

Code

input.kz

Must contain:

multiple discharge options

Error Verification

Actual Compiler Output

error[KORU030]: Resource 'owned' <instance!> was not discharged. Call one of: std.string:free, std.string:release
  --> phantom_semantic_check:17:0

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

Test Configuration

MUST_FAIL