RangeError: Maximum call stack size exceeded
mduan opened this issue · comments
Hi,
So the following example from the readme works fine for me:
var i = 0; while (true) { await { setTimeout (defer(), 1); i++; } }
However, I get RangeError: Maximum call stack size exceeded
when I change while (true)
to while (i < 20000)
as in the following example:
var i = 0; while (i < 20000) { await { setTimeout (defer(), 1); i++; } }
I just started playing with tamejs, so I'm not sure why the behaviour's different for the two examples.
Just ran into the call stack issue myself. Don't know what's going on internally with for loops but your workaround bailed me out!