This repository has been archived on 2025-10-23. You can view files and clone it, but cannot push or open issues or pull requests.
Files
nub-lang-archive/example/program.nub
nub31 e4e2f3ba26 ...
2025-05-17 22:35:08 +02:00

23 lines
294 B
Plaintext

import c
struct Test {
name: ^string
}
struct Test2 {
parent: ^Test
}
global func main(argc: i64, argv: i64) {
name = "Oliver"
parent = new Test {
name = &name
}
test = new Test2 {
parent = &parent
}
printf("%s\n", (&test)^.parent^.name^)
}