edlang/simple.ed
2023-06-09 11:08:40 +02:00

25 lines
280 B
Plaintext

struct Hello {
x: i32,
y: i32,
}
fn test(x: Hello) {
return;
}
fn works(x: i64) -> i64 {
let z = 0;
if 2 == x {
z = x * 2;
} else {
z = x * 3;
}
return z;
}
fn main() -> i64 {
let y = 2;
let z = y;
return works(z);
}