diff --git a/codeGeneration/src/prog8/compiler/target/cpu6502/codegen/AsmGen.kt b/codeGeneration/src/prog8/compiler/target/cpu6502/codegen/AsmGen.kt index d6386d95e..7548a5ef4 100644 --- a/codeGeneration/src/prog8/compiler/target/cpu6502/codegen/AsmGen.kt +++ b/codeGeneration/src/prog8/compiler/target/cpu6502/codegen/AsmGen.kt @@ -1608,9 +1608,8 @@ $label nop""") } - private fun translateComparisonExpressionWithJumpIfFalse(expr: BinaryExpression, jumpIfFalseLabel: String) { - // This is a helper routine called from while, do-util, and if expressions to generate optimized conditional branching code. + // This is a helper routine called from if expressions to generate optimized conditional branching code. // First, if it is of the form: X , then flip the expression so the constant is always the right operand. var left = expr.left diff --git a/docs/source/todo.rst b/docs/source/todo.rst index cf9074baa..73c0469e7 100644 --- a/docs/source/todo.rst +++ b/docs/source/todo.rst @@ -3,6 +3,7 @@ TODO For next compiler release (7.6) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +change desugar of while loop so that no initial jump is required optimize ifs containing only a jump: reuse old code from AsmGen translateComparisonExpressionWithJumpIfFalse?