Files
mgmt/lang/interpret_test/TestAstFunc1/importscope0.txtar
James Shubin 28f5b8331a lang: funcs: structs: Improve naming
These could print nicer for debugging.
2024-12-08 16:24:42 -05:00

29 lines
543 B
Plaintext

-- main.mcl --
import "second.mcl"
include second.xclass
-- second.mcl --
import "os"
import "fmt"
class xclass {
#import "os" # this should not be required, top-level should be enough
$aaa = if os.is_family_debian() { "bbb" } else { "ccc" }
print "${aaa}" {
msg => "hello",
}
}
-- OUTPUT --
Edge: FuncValue -> call # fn
Edge: call -> if # c
Edge: const: str("bbb") -> if # a
Edge: const: str("ccc") -> if # b
Vertex: FuncValue
Vertex: call
Vertex: const: str("bbb")
Vertex: const: str("ccc")
Vertex: const: str("hello")
Vertex: if