[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: issue PROCLAIM-LEXICAL
- To: email@example.com, sandra <@cs.utah.edu:sandra@defun>
- Subject: Re: issue PROCLAIM-LEXICAL
- From: Jeff Dalton <jeff%aiai.edinburgh.ac.uk@NSS.Cs.Ucl.AC.UK>
- Date: Wed, 25 Jan 89 16:26:36 GMT
- Cc: firstname.lastname@example.org
- In-reply-to: email@example.com's message of 23 Jan 89 21:45 PST
> The proposal mentions in passing "It would be possible to submit a proposal
> for a GLOBAL (G) declaration
> under separate cover if anyone (Xerox?) was interested."
I'm still not quite happy with GLOBAL, particularly if it disallows
local lexical variables of the same name. As far as lexical variables
are concerned, the reference can be determined statically. And if it's
to the global, it's to the global. No efficiceny need be lost. That's
what happens in languages without special variables, and it's what
should happen in Lisp for variables that are lexical. So I don't
think the LG proposal had much need for a GLOBAL declaration.
As I understand it, the problem faced by deep-bound implementations
(of special variables) is that they don't know whether there are
any bindings or not and so have to look before fetching the global
value. But I think it's OK for that to happen to variables that
might have special bindings; what's wrong is to have to do it even
though the programmer knows there will never be any bindings.
So if GLOBAL is taken to mean only "there will be no special
bindings", then it's probably OK.
Some implementations allow one to fetch the global value even
thought there are local special bindings. I think such usage
represents a confusion about whether the variable is supposed
to have special bindings or not.
Nonetheless, although I think a limited meaning for GLOBAL is ok,
I still prefer LEXICAL. LEXICAL sunsumes all the reasonable uses