From: Peter Seibel
Subject: History of "special"
Date: 
Message-ID: <m38y90ca8x.fsf@javamonkey.com>
Anyone know when was the term "special" was introduced to mean
"dynamic" variables. Pre-Common Lisp? Presumably in Ye Olde LISP
special variables weren't considered special because that's the only
kind there were.

-Peter

-- 
Peter Seibel                                      ·····@javamonkey.com

         Lisp is the red pill. -- John Fraser, comp.lang.lisp

From: Chris Riesbeck
Subject: Re: History of "special"
Date: 
Message-ID: <criesbeck-BD4C1A.18142117112004@individual.net>
In article <··············@javamonkey.com>,
 Peter Seibel <·····@javamonkey.com> wrote:

> Anyone know when was the term "special" was introduced to mean
> "dynamic" variables. Pre-Common Lisp? Presumably in Ye Olde LISP
> special variables weren't considered special because that's the only
> kind there were.

Maclisp had them.

http://www.multicians.org/lcp.html
From: Karl A. Krueger
Subject: Re: History of "special"
Date: 
Message-ID: <cnhbf9$km6$1@baldur.whoi.edu>
Chris Riesbeck <·········@yahoo.com> wrote:
> In article <··············@javamonkey.com>,
> Peter Seibel <·····@javamonkey.com> wrote:
> 
>> Anyone know when was the term "special" was introduced to mean
>> "dynamic" variables. Pre-Common Lisp? Presumably in Ye Olde LISP
>> special variables weren't considered special because that's the only
>> kind there were.
> 
> Maclisp had them.
> http://www.multicians.org/lcp.html

Hart and Levin's memo on the Lisp 1.5 compiler in 1962 states that "All
free variables in compiled programs must be declared SPECIAL or COMMON."

ftp://publications.ai.mit.edu/ai-publications/pdf/AIM-039.pdf

(I've been researching Lisp history for Wikipedia articles recently.
It's great that a lot of early publications like this one are available
on the Web now ... they go a long way to clearing up misunderstandings
such as "early Lisp systems were interpreters".)

-- 
Karl A. Krueger <········@example.edu> { s/example/whoi/ }

Every program has at least one bug and can be shortened by at least one line.
By induction, every program can be reduced to one line which does not work.
From: Barry Margolin
Subject: Re: History of "special"
Date: 
Message-ID: <barmar-26FE95.21074717112004@comcast.dca.giganews.com>
In article <··············@javamonkey.com>,
 Peter Seibel <·····@javamonkey.com> wrote:

> Anyone know when was the term "special" was introduced to mean
> "dynamic" variables. Pre-Common Lisp? Presumably in Ye Olde LISP
> special variables weren't considered special because that's the only
> kind there were.

In Maclisp, variable bindings were dynamic in the interpreter, but 
defaulted to lexical when compiling.  In most cases, the difference was 
rarely noticed.  The SPECIAL declaration was a way of telling the 
compiler not to compile bindings of that variable in the normal way.

-- 
Barry Margolin, ······@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
From: Tim Bradshaw
Subject: Re: History of "special"
Date: 
Message-ID: <1100781316.620465.184560@f14g2000cwb.googlegroups.com>
Barry Margolin wrote:

> In Maclisp, variable bindings were dynamic in the interpreter, but
> defaulted to lexical when compiling.  In most cases, the difference
was
> rarely noticed.  The SPECIAL declaration was a way of telling the
> compiler not to compile bindings of that variable in the normal way.

Which family of Lisps used FLUID for this? I first used cambridge lisp,
which had the same thing, but used some form like (FLUID x) (not
actually that, but something like it) to say things were dynamic in the
compiler.  Being a lisp-1 things could get really exciting in the
interpreter since you could bind things that were used as functions in
some distant part of the stack.

--tim
From: Peter Seibel
Subject: Re: History of "special"
Date: 
Message-ID: <m3ekirby9k.fsf@javamonkey.com>
In an email Paul Foley pointed out:

> On Wed, 17 Nov 2004 23:43:26 GMT, Peter Seibel wrote:
>
>> Anyone know when was the term "special" was introduced to mean
>> "dynamic" variables. Pre-Common Lisp?
>
> Definitely.  It was there in LISP 1.5
>
>>                                        Presumably in Ye Olde LISP
>> special variables weren't considered special because that's the
>> only kind there were.
>
> Hmm. That's not really true. In Lisp 1.5 there were three kinds of
> variables in compiled code: COMMON, SPECIAL and other. "Other" (I
> don't know if there was a proper name for them) were "lexically
> scoped with holes" (a bit like Python, until fairly recently) --
> they were lexically scoped, but there were no closures; "common"
> variables were on an a-list shared by compiled and interpreted code.

So looking in the _Lisp 1.5 Programmers Manual_. I see that McCarthy's
lisp started the tradition (finally broken in Common Lisp, it seems)
of giving different semantics to compiled and interpreted code. As far
as I can tell COMMON and SPECIAL variables in compiled code are both
what we'd call "dynamic" variables today execept SPECIAL variables
could only be shared between compiled functios while COMMON--being
stored on the alist that is passed to EVAL--were slower but "do
provide complete communication between interpreted and compiled
functions."

-Peter

-- 
Peter Seibel                                      ·····@javamonkey.com

         Lisp is the red pill. -- John Fraser, comp.lang.lisp
From: Bernice Barnett
Subject: Re: History of "special"
Date: 
Message-ID: <419C533B.219BB109@comcast.net>
Peter Seibel wrote:

> In an email Paul Foley pointed out:
>
> > On Wed, 17 Nov 2004 23:43:26 GMT, Peter Seibel wrote:
> >
> >> Anyone know when was the term "special" was introduced to mean
> >> "dynamic" variables. Pre-Common Lisp?
> >
> > Definitely.  It was there in LISP 1.5
> >
> >>                                        Presumably in Ye Olde LISP
> >> special variables weren't considered special because that's the
> >> only kind there were.
> >
> > Hmm. That's not really true. In Lisp 1.5 there were three kinds of
> > variables in compiled code: COMMON, SPECIAL and other. "Other" (I
> > don't know if there was a proper name for them) were "lexically
> > scoped with holes" (a bit like Python, until fairly recently) --
> > they were lexically scoped, but there were no closures; "common"
> > variables were on an a-list shared by compiled and interpreted code.
>
> So looking in the _Lisp 1.5 Programmers Manual_. I see that McCarthy's
> lisp started the tradition (finally broken in Common Lisp, it seems)
> of giving different semantics to compiled and interpreted code. As far
> as I can tell COMMON and SPECIAL variables in compiled code are both
> what we'd call "dynamic" variables today execept SPECIAL variables
> could only be shared between compiled functios while COMMON--being
> stored on the alist that is passed to EVAL--were slower but "do
> provide complete communication between interpreted and compiled
> functions."
>
> -Peter
>
> --
> Peter Seibel                                      ·····@javamonkey.com
>
>          Lisp is the red pill. -- John Fraser, comp.lang.lisp

The difference between compiled and interpreted code was quite annoying. In a
Lisp 1.5 compiler I wrote for the old IBM 360 (bootstrapped from the Q32) in
the 1960's, eval called the compiler on the expression, executed the code, then
marked it for GC. What was fascinating was that this scheme was almost as
fast as the interpreters for BBN and other hacks floating around at the and it
won big if the expression was at all complex. Of course, eval and the compiler
were perfectly compatible.

-- Jeff Barnett