CS153/hw6/hw5programs/tc_struct_ok.oat
jmug cfe502c598 Add all the assignment code.
Signed-off-by: jmug <u.g.a.mariano@gmail.com>
2025-01-24 18:59:28 -08:00

23 lines
181 B
Text

struct A {
int x
}
struct B {
int x;
int y
}
A f() {
return new A {x = 3};
}
B g() {
return new B {x = 3; y = 4};
}
int l() {
var x = f();
x = g();
return 3;
}