008 capacity zero refused

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

Code

input.k

Actual compiler output

error[KORU161]: std/channel:new(bad): capacity 0 is rendezvous — a send whose ok fires on the consumer's take — and that spelling is deferred (docs/CHANNEL.md). Buffered channels take a power of two above zero
  --> tests/regression/600_STDLIB/699_CHANNEL/699_008_capacity_zero_refused/input.k:13:0

Compiler must reject:

Compilation must fail with a diagnostic.

Flows

flow ~std/proto click a branch to expand · @labels scroll to their anchor
std/proto (Reading, source: id: u64 ts: f64)
flow ~new click a branch to expand · @labels scroll to their anchor
new (expr: bad, capacity: 0, source: reading: Reading)

Test Configuration

MUST_ERROR