fixed a regression that for-in was failing to cache the source value

This commit is contained in:
satyr
2010-10-23 22:04:19 +09:00
parent 7b887f065d
commit 0942071517
4 changed files with 37 additions and 40 deletions

View File

@@ -182,7 +182,7 @@ class Mini
@num
m = new Mini
ok (func() for func in m.generate()).join(' ') is '10 10 10'
eq (func() for func in m.generate()).join(' '), '10 10 10'
# Testing a contructor called with varargs.

View File

@@ -101,3 +101,6 @@ learn = ->
ok learn().join(' ') is '1 2 3'
ok rule(101) is 101
f = -> [-> ok no, 'should cache source']
ok yes for k of [f] = f()