mirror of
https://github.com/irmen/prog8.git
synced 2024-11-20 03:32:05 +00:00
fix compiler crash on rol/ror array value
This commit is contained in:
parent
9b952fbc44
commit
c560abedba
@ -596,9 +596,10 @@ internal class BuiltinFunctionsAsmGen(private val program: PtProgram,
|
|||||||
throw AssemblyError("non-array var indexing requires bytes dt")
|
throw AssemblyError("non-array var indexing requires bytes dt")
|
||||||
asmgen.assignExpressionToVariable(arrayvar, "prog8_lib.${operation}_array_u${dt}._arg_target", DataType.UWORD)
|
asmgen.assignExpressionToVariable(arrayvar, "prog8_lib.${operation}_array_u${dt}._arg_target", DataType.UWORD)
|
||||||
} else {
|
} else {
|
||||||
|
val p = arrayvar.parent
|
||||||
val addressOf = PtAddressOf(arrayvar.position)
|
val addressOf = PtAddressOf(arrayvar.position)
|
||||||
addressOf.add(arrayvar)
|
addressOf.add(arrayvar)
|
||||||
addressOf.parent = arrayvar.parent.parent
|
addressOf.parent = p
|
||||||
asmgen.assignExpressionToVariable(addressOf, "prog8_lib.${operation}_array_u${dt}._arg_target", DataType.UWORD)
|
asmgen.assignExpressionToVariable(addressOf, "prog8_lib.${operation}_array_u${dt}._arg_target", DataType.UWORD)
|
||||||
}
|
}
|
||||||
asmgen.assignExpressionToVariable(indexer.index, "prog8_lib.${operation}_array_u${dt}._arg_index", DataType.UBYTE)
|
asmgen.assignExpressionToVariable(indexer.index, "prog8_lib.${operation}_array_u${dt}._arg_index", DataType.UBYTE)
|
||||||
|
@ -3,8 +3,6 @@ TODO
|
|||||||
|
|
||||||
For next minor release
|
For next minor release
|
||||||
^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^
|
||||||
fix compiler crash on test/arithmethic/builtins.p8 and test the others as well
|
|
||||||
|
|
||||||
remove unused variables from IR output, such as sys.wait.jiffies when never calling sys.wait
|
remove unused variables from IR output, such as sys.wait.jiffies when never calling sys.wait
|
||||||
...
|
...
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user