SpookyFM / hscript

Automatically exported from code.google.com/p/hscript
0 stars 0 forks source link

Error: EInvalidIterator(IntIterator) in hscript 2.0 and Haxe 3 #13

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install Haxe3 and hscript 2.0
2. Try this simple example:
   for(i in 0...5) { trace("Hi"); }

What is the expected output? What do you see instead?
Expected: 
Hi
Hi
Hi
Hi
Hi

Instead I get:
Error: EInvalidIterator(IntIterator)

What version of the product are you using? On what operating system?
Haxe 3, HxCPP 3.0, hscript 2.0 - Windows 7 64bit

Please provide any additional information below.
"for" loops are broken. 
using "while" loops is ok

Original issue reported on code.google.com by vuj...@gmail.com on 19 Apr 2013 at 2:02

GoogleCodeExporter commented 9 years ago
I disabled the call to makeIterator in forLoop on line 414 in Interp.hx and it 
seems to work.

var it : IntIterator = /*makeIterator(*/expr(it)/*)*/;

Original comment by ubaldes...@gmail.com on 19 Jan 2014 at 4:16