Number: 214

Date: 20-Mar-84 13':11':13

Submitter: Sannella.PA

Source: JONL.PA

Subject: new GENSYM -- discussion

Lisp Version: 

Description: '
Date': 19 Mar 84 16':43 PST'
From': Masinter.pa'
Subject': Re': Gensym'
In-reply-to': Raim.pasa''s message of Mon, 19 Mar 84 15':47 PST'
To': Raim.pasa'
cc': Masinter.PA, LispCore↑.PA'
'
Marty, I cannot. The GENSYM change was advertised as being backward compatible, but apparently it was not. Can you determine in what way the Boeing code was depending on the old GENSYM behavior?'
'
-----'
'
Date': 19 MAR 84 18':46 PST'
From': JONL.PA'
Subject': Re': Gensym'
To':   Masinter, Raim.pasa'
cc':   LispCore↑, JONL'
'
In response to the message sent  19 Mar 84 16':43 PST from Masinter.pa'
'
Sorry, the new GENSYM was  *not* advertised as being 100% compatible.'
'
The basic problem appears to be that the documentation on it *** isn''t in'
the release message ***  How did this happen?'
'
Anyway, the differences, briefly summarized, are'
  1) you can supply an argument, which becomes the non-numeric prefix for the generated symbol (this shouldnt cause problems unless someone was spuriously passing along an argument to the old gensym)'
  2) the variable GENNUM is initialized at  0 instead of 10000, and there is no limit on the size of the numerical suffix.  Thus if one were to set GENNUM to 1234567 and then call GENSYM, he would get A1234568 instead of A4568.  This part was in the message I sent to Gadol etc in early January documenting the new gensym capabilities [in fact, there are other new capabilities -- all extensions that arent affected by the documented user interface -- byut Tayloe and I were still desiging these when release time came, so it didn''t make sense to document their half-baked state]'
'
So the question to ask is if they are setting GENNUM.  Also, the question to ask is if the GENSYM commentary was ever in the release message and got inadvertently deleted.'
'
-----'
'
Date': 20 Mar 84 18':50 PST'
From': Kaplan.pa'
Subject': Lisp': New GENSYM'
To': JonL, LispSupport.pa'
Lisp-System-Date': 20-Mar-84 18':25':18'
Machine-Type': Dorado'
'
I remember some messages about GENSYM awhile ago, but I thought that there were still open questions about the new proposed design, and that it hadn''t been installed yet.'
'
Looking at the argument list, I can more or less figure out what PREFIX, NUMSUFFIX, and NEW? might mean.  What are OSTRBUFFER and CHARCODE ?'
'
--Ron'
'
-----'
'
Date': 20 Mar 84 18':54 PST'
From': Kaplan.pa'
Subject': Lisp': P.S.  New GENSYM'
To': JonL, LispSupport.pa'
Lisp-System-Date': 20-Mar-84 18':25':18'
Machine-Type': Dorado'
'
Actually, I don''t quite see the need for all this new complexity in GENSYM.  Any user who wanted to do something fancy with prefixes and suffixes could very easily call PACK*.  The only new capability seems to be NEW?, and that could be made available with a separate utility to apply to a string to determine whether an atom with the string as pname already exists.'
'
[Although note that you can''t in general guarantee unique symbols unless you allow uninterned atoms, which is a known disaster.]'
'
--Ron  '
'
-----'
'
Date': Tue, 20 Mar 84 19':58 PST'
From': Raim.pasa'
Subject': Re': Gensym'
In-reply-to': "JONL.PA''s message of 19 MAR 84 18':46 PST"'
To': JONL.PA'
cc': Masinter.PA, Raim, LispCore↑.PA'
Reply-To': Raim.pasa'
'
JonL,'
'
Boeing was assuming GENNUM was initialized to 10000 and, perhaps foolishly, created some dependencies on that being the case.'
'
--Marty'
'
-----'
'
Date': 21 Mar 84 17':40 PST'
From': Masinter.pa'
Subject': resolve GENSYM mess'
To': LispSupport'
'
Attn': Sheil'
'
no other fields'
'
-----'
'
Date': 26 MAR 84 14':31 PST'
From': JONL.PA'
Subject': Fugue.6 release notes -- GENSYM'
To':   Raim.pasa'
cc':   1100Support.pasa, LispCore↑'
'
Should mention that there is no effective upper limit on the numerical'
suffix part of a GENSYM (current documentation only mentions that GENNUM'
is initialized to 0 rather than 10000).  Consequence is that for larger'
values of GENNUM, you get "longer" gensyms (but of course the numerical'
suffix will be left-padded with 0''s to get a minimum length of 5 characters).'
'
Utilization of this extension is not only to make more gensyms available,'
but more gensym  ** names **;  Thus one can imagine (and indeed Tayloe did so for a while) having two separate, independent starting points for GENNUM depending upon which sub-application was running (switiching between these sub-applications involved re-setting GENNUM).'
'
-----'
'
Date': 26 MAR 84 16':50 PST'
From': MASINTER.PA'
Subject': GENSYM'
To':   JonL'
cc':   1100Support.pasa, LispCore↑'
'
There still is the limit that Interlisp-D will only allow 32K symbols, and so thus there IS an effective limit if you start out at GENNUM = 0 of getting to GENNYM = 20000; the change to GENSYM thus doubles the limit, but doesn''t remove it.'
'
Some applications will want to just keep their own counter, e.g., Tayloe could merely'
'
(PACK* "parser" (add PARSERCOUNT 1))'
'
-----'
'
Date':  3 APR 84 21':14 PST'
From': JONL.PA'
Subject': Re': Lisp': New GENSYM'
To':   Kaplan, LispSupport'
cc':   JONL'
'
In response to the message sent  20 Mar 84 18':50 PST from Kaplan.pa'
'
Long ago, Kelly asked similar questions.  Namely, what are the extra'
args to GENSYM for, and why does it appear to be so complicated?'
'
The extra args are only for some "internal" calls; the interface that Tayloe'
and I agreed upon is not yet implemented, so looking beyond what ARGLIST'
or the release documentation gives you will be a waste of time.'
'
However, in defense of apparent complexity, note that the "new" gensym'
is nearly an order  of magnitude faster than the "old" one, and for a'
myriad of gensyms, that amounts to 150 seconds savings (Dolphin timings)!!'
Note also two items of functionality not provided by PACK*':'
  1) the numerical suffix part is extended out with leading zeros to'
     insure a minimal numerical part (Common Lisp does not do this)'
  2)  The "new" option is indeed usefule to some; I''ve previously supplied'
    all the arguments why "new" can''t mean "unique", but the user who'
   requested this feature fully understands, and insists that what he '
   wants is "new", not "unique".'
'
-----'
'
From': MASINTER.pa'
Date':  3-Apr-84 22':45':21 PST'
Subject': Re': GENSYM'
In-reply-to': JONL''s message of 3 APR 84 21':41 PST'
To': JONL'
cc': MASINTER, 1100Support.pasa, LispCore↑'
'
you have never made an argument for why it was necessary to make an incompatible change to GENSYM rather than some new user package, into which you can put all of the complexity you want.'
'
I want to keep the "core" of Interlisp as small and simple as possible. Users have enough trouble finding their way around without being confrunted with a lot of new options in the ''kernel'' of the language.'
'
The only exceptions I can think of are those places where we decide to adopt some feature from CommonLisp into the Interlisp kernel (rather than as a part of a separate ZCommonLisp compatibility package.) In those cases, we must be careful not to differ in any respect fro the CommonLisp specification.'
'
-----'
'
Date':  4 APR 84 12':00 PST'
From': JONL.PA'
Subject': Re': GENSYM'
To':   MASINTER'
cc':   1100Support.pasa, LispCore↑, JONL'
'
In response to your message sent   3-Apr-84 22':45':21 PST'
'
Did I have to make the argument about the broken state of the "old" GENSYM?'
'
Didn''t Doug Lenat already make it?  Didn''t the LOOPS people too?  when'
they found the limitations which the documented change corrected? or finally'
Tayloe?  and the list goes on and on and on.'
'
Larry,  how about being realistic on this case, rather than re-iterating'
general principles that apply in some cases and don''t apply in others.'
'
-----'
'
Date':  4 Apr 84 14':56 PST'
From': Burton.pa'
Subject': Re': GENSYM'
In-reply-to': JONL.PA''s message of 4 APR 84 12':00 PST'
To': JONL.PA'
cc': MASINTER.PA, 1100Support.pasa, LispCore↑.PA'
'
"Did I have to make the argument about the broken state of the "old" GENSYM?"'
'
That is exactly what you had to do, and didn''t do.'
'
richard'
'
-----'
'
Date': 15 APR 84 22':05 PST'
From': MASINTER.PA'
Subject': OLDGENSYM on <LispCore>Library>'
To':   LispSupport'
cc':   Raim.pasa'
'
This is a ''patch'' file for people who don''t want the new gensym but want the old one''s behavior for compatibility.'
'
'


Workaround: 

Test Case: 

Edit-By: Sannella.PA

Edit-Date:  1-May-84 12':38':46

Attn: lisp, Release

Assigned To: Jonl

In/By: 

Disposition: 

System: Language Support

Subsystem: Other

Machine: 

Disk: 

Microcode Version: 

Memory Size: 

File Server: 

Server Software Version: 

Difficulty: Moderate

Frequency: Everytime

Impact: Moderate

Priority: Perhaps

Status: Fixed

Problem Type: Documentation

Source Files: