fixing quite a few bugs
This commit is contained in:
20
test2.grnd
20
test2.grnd
@@ -1,9 +1,17 @@
|
||||
fun -int !add -int &a -int &b
|
||||
add $a $b &a
|
||||
return $a
|
||||
fun -bool !greater -int &x -int &y
|
||||
greater $x $y &x
|
||||
return $x
|
||||
endfun
|
||||
|
||||
pusharg 1
|
||||
pusharg 4
|
||||
call !add &result
|
||||
end $result
|
||||
pusharg 3
|
||||
call !greater &bigger
|
||||
|
||||
if $bigger %yes
|
||||
jump %no
|
||||
@yes
|
||||
stdout "yep!\n"
|
||||
end 0
|
||||
@no
|
||||
stdout "nope...\n"
|
||||
end 0
|
Reference in New Issue
Block a user