ref: b7b03ee4510f1dd3f8b7dfdbe4a21d5c0d9bfeb2
parent: f9b48c0cad60a45625180e71ced52179b07c3d94
author: ISSOtm <[email protected]>
date: Tue Aug 18 08:34:05 EDT 2020
Fix "REPT 0" not being a no-op
--- a/src/asm/fstack.c
+++ b/src/asm/fstack.c
@@ -258,6 +258,8 @@
{
dbgPrint("Running REPT(%" PRIu32 ")\n", count);
+ if (count == 0)
+ return;
uint32_t reptDepth = contextStack->reptDepth;
newContext(reptDepth + 1);
--- /dev/null
+++ b/test/asm/rept-0.asm
@@ -1,0 +1,3 @@
+REPT 0
+ WARN "2"
+ENDR