✓
Passing Passing: the compiler rejects this program as expected.
Code
// PINS: a tor is declared in its own module. `m:speech` asks this file to
// declare a tor inside module `m` — the qualified spelling is the IMPL
// side's (`~proc m:name` implements a contract where it lives), never the
// declaration's.
import std/io
tor m:speech {}
Actual compiler output
error[PARSE003]: a tor is declared in its own module — 'm:name' is the impl side's spelling ('~proc m:name' serves a contract where it lives)
--> tests/regression/200_COMPILER_FEATURES/210_PARSER/210_306_tor_module_qualified_name_refused/input.k:7:6
|
7 | tor m:speech {}
| ^Frontend must reject with:
CONTAINS error[PARSE003]
ERROR_AT 7
NOT_CONTAINS output_emitted.zigTest Configuration
MUST_ERROR