2021-11-27 18:09:15 +01:00
|
|
|
%import test_stack
|
2021-10-27 23:48:02 +02:00
|
|
|
|
2021-10-30 15:15:11 +02:00
|
|
|
main {
|
2021-11-06 19:09:33 +01:00
|
|
|
|
2021-11-10 00:17:56 +01:00
|
|
|
sub start() {
|
2021-11-27 18:09:15 +01:00
|
|
|
test_stack.test()
|
|
|
|
|
|
|
|
sys.push(-22 as ubyte)
|
|
|
|
sys.push(44)
|
|
|
|
sys.pushw(-11234 as uword)
|
|
|
|
sys.pushw(12345)
|
|
|
|
sys.push(1)
|
|
|
|
sys.push(2)
|
|
|
|
ubyte @shared ub = sys.pop()
|
|
|
|
byte @shared bb = sys.pop() as byte
|
|
|
|
uword @shared uw = sys.popw()
|
|
|
|
word @shared ww = sys.popw() as word
|
|
|
|
void sys.pop()
|
|
|
|
void sys.pop()
|
|
|
|
|
|
|
|
; routine2(uw+1, true)
|
|
|
|
|
|
|
|
test_stack.test()
|
2021-11-21 00:07:17 +01:00
|
|
|
|
|
|
|
repeat {
|
|
|
|
}
|
2021-11-27 14:08:34 +01:00
|
|
|
|
2021-11-16 23:52:30 +01:00
|
|
|
}
|
2021-11-21 12:34:57 +01:00
|
|
|
|
2021-11-27 15:41:44 +01:00
|
|
|
asmsub routine2(uword num @AY, ubyte switch @X) {
|
2021-11-21 23:21:39 +01:00
|
|
|
%asm {{
|
2021-11-26 22:11:52 +01:00
|
|
|
adc #20
|
2021-11-21 23:21:39 +01:00
|
|
|
rts
|
|
|
|
}}
|
2021-11-21 16:23:48 +01:00
|
|
|
}
|
2021-11-21 23:21:39 +01:00
|
|
|
|
2021-05-13 00:35:22 +02:00
|
|
|
}
|