130 record ctor names undeclared field

✓ Passing Passing: the compiler rejects this program as expected.

Code

input.k

Actual compiler output

error[KORU030]: constructor field 'c' is not a field of branch 'ok' (payload fields: a, b)
  --> tests/regression/500_INTEGRATION_TESTING/510_NEGATIVE_TESTS/510_130_record_ctor_names_undeclared_field/input.k:21:1
    |
 21 | pick => ok { c: 3, d: 4 }
    | ^
  hint: a record-payload constructor supplies every declared field and no others

error[KORU030]: constructor field 'd' is not a field of branch 'ok' (payload fields: a, b)
  --> tests/regression/500_INTEGRATION_TESTING/510_NEGATIVE_TESTS/510_130_record_ctor_names_undeclared_field/input.k:21:1
    |
 21 | pick => ok { c: 3, d: 4 }
    | ^
  hint: a record-payload constructor supplies every declared field and no others

error[KORU030]: branch 'ok' declares payload field 'a' the constructor does not supply — every constructor supplies the field explicitly
  --> tests/regression/500_INTEGRATION_TESTING/510_NEGATIVE_TESTS/510_130_record_ctor_names_undeclared_field/input.k:21:1
    |
 21 | pick => ok { c: 3, d: 4 }
    | ^
  hint: add 'a: <value>' to the constructor

error[KORU030]: branch 'ok' declares payload field 'b' the constructor does not supply — every constructor supplies the field explicitly
  --> tests/regression/500_INTEGRATION_TESTING/510_NEGATIVE_TESTS/510_130_record_ctor_names_undeclared_field/input.k:21:1
    |
 21 | pick => ok { c: 3, d: 4 }
    | ^
  hint: add 'b: <value>' to the constructor

Frontend must reject with:

NOT_CONTAINS output_emitted.zig
CONTAINS KORU030
CONTAINS is not a field of branch 'ok'

Flows

flow ~pick click a branch to expand · @labels scroll to their anchor
pick (x: 1)

Test Configuration

MUST_ERROR