mirror of
https://github.com/irmen/prog8.git
synced 2024-12-24 16:29:21 +00:00
fix some invalid instructions on 6502 (instead of 65c02) target for bit shifts
This commit is contained in:
parent
be06d871b6
commit
75514fc7af
@ -602,7 +602,7 @@ internal class AssignmentAsmGen(private val program: PtProgram,
|
||||
asmgen.out(" pha")
|
||||
if(dt in ByteDatatypes) {
|
||||
assignExpressionToRegister(expr.left, RegisterOrPair.A, signed)
|
||||
asmgen.out(" ply")
|
||||
asmgen.restoreRegisterStack(CpuRegister.Y, true)
|
||||
if(expr.operator==">>")
|
||||
if(signed)
|
||||
asmgen.out(" jsr math.lsr_byte_A")
|
||||
@ -614,7 +614,7 @@ internal class AssignmentAsmGen(private val program: PtProgram,
|
||||
return true
|
||||
} else {
|
||||
assignExpressionToRegister(expr.left, RegisterOrPair.AY, signed)
|
||||
asmgen.out(" plx")
|
||||
asmgen.restoreRegisterStack(CpuRegister.X, true)
|
||||
if(expr.operator==">>")
|
||||
if(signed)
|
||||
asmgen.out(" jsr math.lsr_word_AY")
|
||||
|
Loading…
Reference in New Issue
Block a user