repo.or.cz
/
voodoo-lang.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Removed superfluous debug comments from ARM generator
[voodoo-lang.git]
/
test
/
set-at.voo
blob
153866b512e70b72d3d7109d36c77712cc18c1a2
1
#### Test program for set with at-expressions
2
3
section data
4
5
foo:
6
word 0
7
8
bar:
9
word 42
10
11
fmt:
12
string "%d\n\x00"
13
14
15
section functions
16
import printf
17
export main
18
19
main:
20
function argc argv
21
call printf fmt @foo
22
set @foo 1
23
call printf fmt @foo
24
set @foo add 2 3
25
call printf fmt @foo
26
set @foo @bar
27
call printf fmt @foo
28
let x 9
29
set @foo x
30
call printf fmt @foo
31
set @foo add x @bar
32
call printf fmt @foo
33
set x bar
34
set @foo @x
35
call printf fmt @foo
36
set @foo add @x @bar
37
call printf fmt @foo
38
return 0
39
end function