We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2ac7095 commit 2a2d152Copy full SHA for 2a2d152
src/compiler/jsgen.js
@@ -610,7 +610,7 @@ class JSGenerator {
610
break;
611
case StackOpcode.CONTROL_REPEAT: {
612
const i = this.localVariables.next();
613
- if (node.times.isAlwaysType(InputType.NUMBER_INT)) {
+ if (node.times.isAlwaysType(InputType.NUMBER_INT | InputType.NUMBER_INF)) {
614
this.source += `for (var ${i} = ${this.descendInput(node.times)}; ${i} > 0; ${i}--) {\n`;
615
} else {
616
this.source += `for (var ${i} = ${this.descendInput(node.times)}; ${i} >= 0.5; ${i}--) {\n`;
0 commit comments