Nп/п : 54 из 93
 От   : Spiros Bousbouras                   2:5075/128        31 авг 23 18:57:40
 К    : Tom Russ                                              31 авг 23 21:59:02
 Тема : Re: What does (gensym) generate?
----------------------------------------------------------------------------------
                                                                                 
@MSGID: <hwL2ZQGx9qWcVmVLY@bongo-ra.co> 1bc564b7
@REPLY:
<75e51292-e706-4e7e-8aa2-8c8327c71f4fn@googlegroups.com> df690fa7
@REPLYADDR Spiros Bousbouras <spibou@gmail.com>
@REPLYTO 2:5075/128 Spiros Bousbouras
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID: <hwL2ZQGx9qWcVmVLY@bongo-ra.co>
@RFC-References:
<75e51292-e706-4e7e-8aa2-8c8327c71f4fn@googlegroups.com>
@TZUTC: -0000
@TID: FIDOGATE-5.12-ge4e8b94
On Thu, 31 Aug 2023 11:18:56 -0700 (PDT)
Tom Russ <taruss@google.com> wrote:
> On Thursday, August 31, 2023 at 2:11:21 AM UTC-7, none albert wrote:
> > The explanations about the usage of gensym are clear, 
> > how your are supposed to used them. 
> > The theoretical background however is far from it. 

> The theoretical background is essentially this:
> * For regular symbols, when the reader encounters a symbol, it creates a
>    symbol object and "interns" it. Interning means creating a mapping from
>    the symbol name to the symbol object.

No , interning means creating an association between a symbol and a package.
Different packages can have symbols with the same name. Other relevant facts
{for Common Lisp} :

A name is a string and each symbol has a name and it can even be the empty
string.

Each package can have at most 1 symbol with a given name.

You can have an unlimited number of uninterned symbols with a given name.

> * GENSYM will generate an "uninterned" symbol. It creates and returns a
>    symbol object, but does *not* create a mapping from the (generated)
>    name to the symbol object. That means that even if you type in the same
>    as gets internally chosen for this uninterned symbol, it will not be the
>    same object.
--- FIDOGATE 5.12-ge4e8b94
 * Origin: A noiseless patient Spider (2:5075/128)
SEEN-BY: 5001/100 5005/49 5015/255 5019/40 5020/715
848 1042 4441 12000
SEEN-BY: 5030/49 1081 5058/104 5075/128
@PATH: 5075/128 5020/1042 4441



   GoldED+ VK   │                                                 │   09:55:30    
                                                                                
В этой области больше нет сообщений.

Остаться здесь
Перейти к списку сообщений
Перейти к списку эх