On Mon, Mar 29, 2010 at 10:36 AM, Alessandro Serra <gas.hale@gmail.com> wrote:
Hi all,
I was playing with "memoize" when I found out that I cannot do it with
recursive compiled functions. A recursive function is usually compiled
as:[...]
> (setf (symbol-function 'f) ...)
 has not effect on the recursive calls of f.
I'm not an expert of common lisp standard. I would like to know if the
ecl's behaviour is correct.

Yes, it is. Compiled functions in can use direct references to the code they want to invoke, instead of going through the symbol. Just add (declare (notinline f)) to the top of the function code.

Juanjo

--
Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
http://tream.dreamhosters.com