You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I unwittingly created a cyclic import that bypassed the compiler. Here's the minimal reproduction:
main.odin
package main
import"cool:b"import"core:fmt"
main :: proc() {
fmt.println("Hellope", b.pro())
}
a/a.odin
package a
import"cool:a"import"cool:b"
N :: 96
pro :: proc() -> int {
return b.M * 2
}
b/b.odin
package b
import"cool:b"import"cool:a"
M :: 16
pro :: proc() -> int {
return a.pro() + a.N
}
Run with odin run . -collection:cool=. and see that it compiles and outputs Hellope 128. It seems like the package itself must import itself before any others in order to bypass the restriction. Tested with odin version dev-2025-03:4b2b49dc3.
The text was updated successfully, but these errors were encountered:
I unwittingly created a cyclic import that bypassed the compiler. Here's the minimal reproduction:
main.odin
a/a.odin
b/b.odin
Run with
odin run . -collection:cool=.
and see that it compiles and outputsHellope 128
. It seems like the package itself must import itself before any others in order to bypass the restriction. Tested withodin version dev-2025-03:4b2b49dc3
.The text was updated successfully, but these errors were encountered: