✓
Passing Passing: the compiler rejects this program as expected.
Code
// One home, one File. A second registration of the same foreign entry is
// the same loud collision as any other identity door — the airlock mints
// once, never merges.
import std/foreign
std/foreign:struct(File) {
path
}
std/foreign:struct(File) {
handle
}
Actual compiler output
error[KORU030]: duplicate foreign entry 'File' — a foreign entry is registered once; the declaration at tests/regression/600_STDLIB/667_FOREIGN/667_002_duplicate_foreign_refused/input.k:10 collides with the prior registration at tests/regression/600_STDLIB/667_FOREIGN/667_002_duplicate_foreign_refused/input.k:6
--> tests/regression/600_STDLIB/667_FOREIGN/667_002_duplicate_foreign_refused/input.k:10:0
❌ Compiler coordination error: Phantom semantic validation failed
(set KORU_BACKEND_TRACE=1 for the backend return trace)Compiler must reject:
Compilation must fail with a diagnostic.
Flows
flow ~struct click a branch to expand · @labels scroll to their anchor
struct (expr: File, source: path)
flow ~struct click a branch to expand · @labels scroll to their anchor
struct (expr: File, source: handle)
Test Configuration
MUST_ERROR