✓
Passing Passing: the compiler rejects this program as expected.
Code
// A short-form module qualifier is rejected: `io:print.ln` where the module is
// `std/io`. Koru has no import aliases — a qualifier is always the full path,
// so the leading segment of an import is never a name you may call through.
//
// What this pins is the REJECTION, not the wording. The diagnostic today is
// KORU040 "unknown tor", which lands the program in the right place by the
// UPDATED 2026-11-15: the wall moved to the frontend (KORU040 now names the
// real call `io:print.ln` and teaches `import io`) — pin tightened to the new
// stage+message per the note below's own instruction.
//
// Former note: it reports a missing tor rather than a malformed qualifier, and
// it names `io:print.impl` — a symbol the user never wrote. Both were message
// quality, tracked separately; if the wall ever moves to a qualifier-specific
// diagnostic this pin should be tightened to name it.
~import std/io
~tor test {}
~proc test|zig {
}
// This should FAIL - "io" is not a valid module qualifier
// Correct form is: std/io:println
~test() |> io:print.ln("WRONG - should be std/io:println")
Actual compiler output
error[KORU040]: call to `io:print.ln` cannot be resolved — module `io` declares nothing in this program
--> tests/regression/500_INTEGRATION_TESTING/510_NEGATIVE_TESTS/510_011_invalid_module_qualifier/input.kz:25:1
|
25 | ~test() |> io:print.ln("WRONG - should be std/io:println")
| ^
hint: if `io` is a module, it needs `import io` at file scope (`~import io` in a .kz)Frontend must reject with:
CONTAINS KORU040
CONTAINS io:printFlows
flow ~test click a branch to expand · @labels scroll to their anchor
test
Test Configuration
MUST_ERROR