ona/debug/app.ona

34 lines
398 B
Plaintext
Raw Normal View History

2023-05-24 01:22:29 +02:00
var printer = lambda (pfx):
return lambda (msg):
@print("This is a func call")
@print(msg)
end
2023-08-26 17:00:17 +02:00
end
let pr = printer("This is a func call")
var i = 0
pr("")
2023-08-25 00:45:29 +02:00
while i < 5:
2023-08-26 17:00:17 +02:00
pr("hello, world")
2023-08-13 03:03:43 +02:00
2023-08-23 00:49:23 +02:00
i = i + 1
end
2023-08-25 00:45:29 +02:00
if i > 6:
2023-08-26 17:00:17 +02:00
pr("`i` greater than `6`")
2023-08-25 00:45:29 +02:00
elif i == 4:
2023-08-26 17:00:17 +02:00
pr("`i` is equal to `4`")
2023-08-25 00:45:29 +02:00
else:
2023-08-26 17:00:17 +02:00
pr("i'unno")
2023-08-25 00:45:29 +02:00
end
2023-08-23 00:49:23 +02:00
return {
.title = "Game",
.width = 1280,
.height = 800,
.tick_rate = 60,
2023-05-24 01:22:29 +02:00
}