Commit 83f4ea appears to have implemented return values from loop
expressions, which is great and something I've wanted for a long time.
But there seems to be a bug insofar as the return values never
actually get returned:
An example is this FOR loop - foo() should return 40 but returns NaN (10 * null) instead:
(defun foo ()
(* 10 (for ((i 0)) ((< i 10)) ((incf i))
(when (> i 3)
(return i)))))
=>
function foo() {
return 10 * (function () {
var loopResultVar6945 = null;
for (var i = 0; i < 10; ++i) {
if (i > 3) {
loopResultVar6945 = i;
break;
};
};
loopResultVar6945;
})();
};
I get the same result using the LOOP macro, and WHILE loops have the same problem.
Daniel