mirror of
https://github.com/Noratrieb/riverdelta.git
synced 2026-01-14 16:35:03 +01:00
21 lines
No EOL
301 B
Text
21 lines
No EOL
301 B
Text
//@check-pass
|
|
|
|
type A = struct { a: Int };
|
|
type Complex = struct {
|
|
a: Int,
|
|
b: (Int, A),
|
|
};
|
|
|
|
function main() = (
|
|
let a = A { a: 0 };
|
|
// let b = 0;
|
|
// let c = Complex { a: 0, b: (0, a) };
|
|
|
|
write(a);
|
|
|
|
// c.b.1.a = 1; TODO
|
|
);
|
|
|
|
function write(a: A) = a.a = 1;
|
|
|
|
function ret(): A = A { a: 0 }; |