It seems that the looping constructs don't currently return a value. In other
words, they don't return an array of the results. CoffeeScript allows for both
scenarios, that is, looping for side-effects and looping that returns an array
of results. I'm thinking it would be very useful to have dotimes*, dolist*,
for-in*, etc. that return an array of results. Below is an example from
coffeescript.org. Let me know what you think.
David
countdown = (num for num in [10..1])
------------------------------------
var countdown, num;
countdown = (function() {
var _i, _results;
_results = [];
for (num = _i = 10; _i >= 1; num = --_i) {
_results.push(num);
}
return _results;
})();
_______________________________________________
parenscript-devel mailing list
[email protected]
http://lists.common-lisp.net/cgi-bin/mailman/listinfo/parenscript-devel