321 thread ambiguity not dissolved by scope

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

Code

input.k

Actual compiler output

error[KORU093]: 'consume' has 2 unfilled parameters accepting a string: 'a', 'b' — the thread cannot elect between them
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_321_thread_ambiguity_not_dissolved_by_scope/input.k:19:0
    |
 19 | other(): o |> produce() |> consume()
    | ^
  hint: write one of them at the call site; the thread fills whichever is left open (writing narrows, and what you write binds by name)

error[KORU092]: the string produced by 'produce' has nowhere to land — every parameter downstream that could take it is already written
  --> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_321_thread_ambiguity_not_dissolved_by_scope/input.k:19:0
    |
 19 | other(): o |> produce() |> consume()
    | ^
  hint: leave the slot that should take it unfilled so the thread elects it, or drop the value at its source with `: _`. An unnamed produce cannot be referenced; `|>` forwards it or refuses.

Must fail at frontend compile:

Parsing or type-checking must reject the program.

Error output must contain

KORU093

Flows

flow ~other click a branch to expand · @labels scroll to their anchor
other

Test Configuration

MUST_ERROR LANGUAGES: zig