aboutsummaryrefslogtreecommitdiffstats
path: root/tests/loops.bad
blob: d42716f3c79d944e7eafbe8ebf88b6492a4197c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
; The most basic loop is the while loop.
while (true) "heelo"

while (1 + 2 == 3) {
    "hello"
}

let a = true
while (a) {
    "hello"
}

; We could use some sugar for this.
let i = 0
while (i < 10) {
    "hello"
    ; --i
}
; TODO: add post/pre increment tokens
; TODO: add functions
; TODO: add function calls

; for let i = 1, 1 < 10, i++ {

; }