[Openmcl-devel] destructuring-bind breaks tail-recursion optimization

Ron Garret ron at flownet.com
Tue Feb 9 08:21:59 UTC 2010


SLSIA.  Is this intentional, or is it a bug?

? (defun baz (n)
  (let ((x n))
    (if (< x 0) t (baz (1- x)))))
BAZ
? (defun foo (n)
  (destructuring-bind (x) (list n)
    (if (< x 0) t (foo (1- x)))))
FOO
? (baz 100000)
T
? (foo 100000)
> Error: Stack overflow on temp stack.
> While executing: FOO, in process Listener(7).




More information about the Openmcl-devel mailing list