1
0
mirror of https://gitlab.com/camelot/kickc.git synced 2024-11-16 21:07:56 +00:00
kickc/src/test/ref/pointer-cast-4.asm

25 lines
411 B
NASM

// Tests casting pointer types to other pointer types does not produce any ASM code
.pc = $801 "Basic"
:BasicUpstart(main)
.pc = $80d "Program"
main: {
.label bscreen = $400
.label wscreen = bscreen
ldx #0
__b1:
// wscreen[i] = (word)i
txa
asl
tay
txa
sta wscreen,y
lda #0
sta wscreen+1,y
// for(byte i: 0..2)
inx
cpx #3
bne __b1
// }
rts
}