From 0b37b5149d2fc56221267936753362bddce2ce4a Mon Sep 17 00:00:00 2001 From: "Barton E. Schaefer" Date: Wed, 27 Jan 2016 22:10:03 -0800 Subject: 37804 (plus 37816): first word following "repeat" should be evaluated as math --- Src/loop.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Src/loop.c') diff --git a/Src/loop.c b/Src/loop.c index 4def9b652..19d7f733e 100644 --- a/Src/loop.c +++ b/Src/loop.c @@ -493,7 +493,9 @@ execrepeat(Estate state, UNUSED(int do_exec)) tmp = ecgetstr(state, EC_DUPTOK, &htok); if (htok) singsub(&tmp); - count = atoi(tmp); + count = mathevali(tmp); + if (errflag) + return 1; pushheap(); cmdpush(CS_REPEAT); loops++; -- cgit 1.4.1