Another inconsistency in for x in range loop
for i in range(10):
pass
print(i)
Will print 9 in python, but 10 in javascript, because the loop is unrolled into for (var i=0; i<10; i++)
Easy to solve but will cost some (very limited) performance. Changing it may also break some user code. Another switch? I am in doubt...
IMHO transcrypt is too bugged and fragile in current state anyway, to worry about breaking existing code. Those people who are seriously using it (like me) are kamikaze and already expect things to blow up at any moment :)
Jokes aside I think consistency with CPython very important and should be rejected only if it adds significant overhead. This is what makes Transcrypt better than RapydScript and alikes. I understand that with transcrypt's design 100% compatability with CPython cannot be achieved, but I think it is a good idea to strive for it everywhere possible.
To me the most important part of Transcrypt is ability to run the same code both in CPython and in JavaScript, reusing the same code on front-end and on back-end. Minor hiccups like this issue are extremely annoying.
No need for an extra switch, just fix it! :)