[Openmcl-devel] Compiler warnings

Rainer Joswig joswig at lisp.de
Mon Oct 19 15:50:48 PDT 2009


Am 18.10.2009 um 19:45 schrieb Tim Bradshaw:

> On 18 Oct 2009, at 18:07, Taoufik Dachraoui wrote:
>
>> n the specs it is said that there is three kinds of variables:
>> lexical, dynamic and constant,
>> and this is the problem, it seems that the hash on SETF creates a
>> variable that is neither
>> lexical, nor dynamic nor constant (as show in previous submissions);
>> So the question
>> is what is the rational behind this hack? why the hack did not
>> create a dynamic variable as in CMUCL?
>
> One of the most annoying things about SETF at the top-level in CMUCL
> is that it does (or did) effectively declare the name as special.
> That can have fairly pervasive and unfortunate side-effects.

I always found that highly annoying.

The CMUCL FAQ has already been mentioned. Just to make it clear,  
fortunately there is a switch for CMUCL to get rid of this:

* (describe 'ext:*top-level-auto-declare*)

*TOP-LEVEL-AUTO-DECLARE* is an external symbol in the EXTENSIONS  
package.
It is a special variable; its value is :WARN.
    WARN is an external symbol in the KEYWORD package.
    It is a constant; its value is :WARN.
Special documentation:
   This variable controls whether assignments to unknown variables at  
top-level
    (or in any other call to EVAL of SETQ) will implicitly declare the  
variable
    SPECIAL.  These values are meaningful:
      :WARN  -- Print a warning, but declare the variable special (the  
default.)
       T     -- Quietly declare the variable special.
       NIL   -- Never declare the variable, giving warnings on each use.

Whenever I use CMUCL and get annoyed with this, I'll set this variable  
in the CMUCL init file.


back to CCL...



>
> So it's a good thing it does not do this in CCL.
> _______________________________________________
> Openmcl-devel mailing list
> Openmcl-devel at clozure.com
> http://clozure.com/mailman/listinfo/openmcl-devel

Rainer Joswig, Hamburg, Germany
http://lispm.dyndns.org/
mailto:joswig at lisp.de



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clozure.com/pipermail/openmcl-devel/attachments/20091020/d7da0656/attachment.htm>


More information about the Openmcl-devel mailing list