brushtail icon indicating copy to clipboard operation
brushtail copied to clipboard

JS AST rewriter for tail call elimination

Results 3 brushtail issues
Sort by recently updated
recently updated
newest added

We can no longer be sure these are tail calls; they likely aren't. We can use escope again here. Either way, it should take into account variable declarations, function declarations,...

This will make contribution a whole lot easier.

The following code breaks. ``` function factorial_cps(n, k) { if (n === 0) return k(1); return factorial_cps( n - 1, function(result) { return k(n * result); }); } function identity(x)...

bug