From: Jim Pryor Date: Sun, 17 Oct 2010 18:45:07 +0000 (-0400) Subject: code cleanup X-Git-Url: http://lambda.jimpryor.net/git/gitweb.cgi?p=lambda.git;a=commitdiff_plain;h=5929fcd429d7f933857ca06b7cb98d6c2086044c code cleanup Signed-off-by: Jim Pryor --- diff --git a/code/lambda.js b/code/lambda.js index d4e3a5ef..83ae7c4a 100644 --- a/code/lambda.js +++ b/code/lambda.js @@ -423,6 +423,7 @@ function reduce(expr, eta, cbv) { return expr.eval_cbv(cbv > 1); } else { // return expr.eval_loop([], eta); + // using trampoline to reduce call stack overflows var to_eval = expr, res = [[], eta]; while (to_eval !== null) { res = to_eval.eval_loop.apply(to_eval, res);