From ... From: Erik Naggum Subject: Re: defvar and (declaim (special ...)) Date: 1999/04/13 Message-ID: <3132955585679736@naggum.no>#1/1 X-Deja-AN: 465701348 References: mail-copies-to: never Organization: Naggum Software; +47 8800 8879; http://www.naggum.no Newsgroups: comp.lang.lisp * Barry Margolin | My .emacs has lots of (setq ) expressions for variables | that are defined in files that I autoload. The autoloaded files won't be | loaded until I actually try to use one of those facilities. I don't need | declarations, because the Emacs byte compiler doesn't warn about these | expressions, not to mention that SPECIAL declarations are meaningless in | Emacs Lisp, since it's dynamically scoped. But if Emacs required | pre-declaration of these variables, I would use DECLAIM rather than | DEFVAR, to avoid the "multiple DEFVAR of same variable" issue. what good would a declaration do, though? SETQ at top-level would write to the value slot of the symbol, and it doesn't matter much whether the symbol is declared special or not at this time. the first DEFVAR to come around would declare it special, but at that time, BOUNDP would be true of that symbol, so DEFVAR wouldn't touch the value. #:Erik