Commit Graph

14 Commits

Author SHA1 Message Date
Jo Liss 57e109ff11 Use "index" for index variable in for loop
This confused me every time I Ctrl+F'ed the home page for "index" and only got
this cryptic statement:

"Comprehensions replace (and compile into) for loops, with optional guard clauses
and the value of the current array index."

Now I can see how the index is used in the code.
2011-11-23 16:25:21 +01:00
Will Bailey 98cc7eb149 [docs] examples of using guards and indices in array comprehensions 2011-09-11 12:43:39 -07:00
Jeremy Ashkenas 06647bdd0a Adding warning about accidentally-comprehended-functions. Issue #896. 2010-12-05 15:29:28 -05:00
Jeremy Ashkenas 69d2048ccc Re-enabling garbage collection of tempvars, only at function boundaries. 2010-10-06 21:19:05 -04:00
Jeremy Ashkenas d4dac214ab optimizing comprehensions source references 2010-10-06 21:13:11 -04:00
Jeremy Ashkenas 980a663c19 ported and regenerated examples. 2010-07-29 00:51:35 -04:00
Jeremy Ashkenas dc7f4b4be0 new live 'Try CoffeeScript' 2010-02-25 20:39:34 -05:00
Jeremy Ashkenas 2875de5e73 changed the docs for optional parens 2010-01-25 00:14:00 -05:00
Jeremy Ashkenas 6e63a18f86 first pass at 0.2.0 docs 2010-01-04 22:19:45 -05:00
Jeremy Ashkenas c3d0e50e8f fixing the food/eat array comprehension in the docs to not pretend like there's a made-up method on String.prototype 2010-01-01 17:16:34 -05:00
Jeremy Ashkenas 6ddd808f74 removing dots from whitespace examples 2009-12-30 00:22:27 -05:00
Jeremy Ashkenas 7b5b261743 removed unused example 2009-12-28 20:05:14 -05:00
Jeremy Ashkenas ff78546465 added array comprehensions over ranges 2009-12-26 00:16:40 -08:00
Jeremy Ashkenas d46bf8ee71 moved the coffeescript extension over from .cs to .coffee -- let's leave C# in peace. Changed array comprehensions to always return their mapped result, even when unassigned 2009-12-25 14:18:05 -08:00