<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">I would like to recap the issues:<div><br></div><div>1. (THE type form) </div><div>should compares type with the type of the returned value of form</div><div><br></div><div>2. at top-level</div><div>(SETF var form)</div><div>defines a variable that is not dynamic but and not exactly lexical either, because</div><div>we cannot declare a lexical variable as special. But the variables defined</div><div>by SETF are not dynamic and we can declare them as special. So the vaiable</div><div>is not dynamic and is not lexical.</div><div><br></div><div>I think that SETF should define a global lexical variable if the variable is not </div><div>previously defined by DEFVAR or DEFPARAMETER (unlike CMUCL SETF se below).</div><div><br></div><div>Recall that I showed an example of SETF in CMUCL. CMUCL SETF defines a special</div><div>variable and raises a warning because the variable was not declared using DEFVAR or </div><div>DEFPARAMETER.</div><div><br></div><div>I think someone should carrefully look at this issues and decide what to do with them.</div><div><br></div><div>Taoufik</div><div><br></div><div><br><div><div>On Oct 18, 2009, at 1:21 PM, Ron Garret wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Oct 18, 2009, at 4:14 AM, Taoufik Dachraoui wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Also, I would like to insist on the fact that SETF creates a lexical variable (on behavior at least,<div><div>it is weird for me to say that because for me when I learned Common Lisp I was told that</div><div>there a daynamic and lexical variables).</div></div></div></blockquote><div><br></div><div>Insist all you want, that won't make you right.</div><br><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>The following example shows that SETF creates a lexical variable (because f always returns</div><div>the value of x as defined by SETF)</div></div></div></blockquote><div><br></div><div>No, it doesn't:</div><div><br></div><div><div>? (setf x 1)</div><div>1</div><div>? (defun f () (+ x 1))</div><div>;Compiler warnings :</div><div>; In F: Undeclared free variable X</div><div>F</div><div>? (let ((x pi)) (declare (special x)) (f))</div><div>4.141592653589793D0</div><div>? x</div><div>1</div><div>? </div></div><br><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div><br></div><div><div>If you do not agree please explain in more details so I learn and understand something new.</div><div><font class="Apple-style-span" color="#000000"><font class="Apple-style-span" color="#144FAE"><br></font></font></div></div></div></div></blockquote><br></div><div>See:</div><div><br></div><div><a href="http://www.flownet.com/ron/specials.pdf">http://www.flownet.com/ron/specials.pdf</a></div><div><br></div><div>rg</div><div><br></div><br></div></blockquote></div><br></div></body></html>