[Openmcl-devel] Compiler warnings

Ron Garret ron at flownet.com
Sun Oct 18 11:21:53 UTC 2009

On Oct 18, 2009, at 4:14 AM, Taoufik Dachraoui wrote:

> Also, I would like to insist on the fact that SETF creates a lexical  
> variable (on behavior at least,
> it is weird for me to say that because for me when I learned Common  
> Lisp I was told that
> there a daynamic and lexical variables).

Insist all you want, that won't make you right.

> The following example shows that SETF creates a lexical variable  
> (because f always returns
> the value of x as defined by SETF)

No, it doesn't:

? (setf x 1)
? (defun f () (+ x 1))
;Compiler warnings :
;   In F: Undeclared free variable X
? (let ((x pi)) (declare (special x)) (f))
? x

> If you do not agree please explain in more details so I learn and  
> understand something new.




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.clozure.com/pipermail/openmcl-devel/attachments/20091018/42e2b843/attachment.html>

More information about the Openmcl-devel mailing list