Re: can I make a list of records?
Re: can I make a list of records?
- Subject: Re: can I make a list of records?
- From: email@hidden
- Date: Tue, 29 Jan 2002 21:39:47 -0500
On Tue, 29 Jan 2002 17:53:51 +0100, "Serge Belleudy-d'Espinose"
<email@hidden> suggested,
>
set myVar to {} as list
>
set myVar to myVar & {myRec:"rec"}
>
class of myVar
>
-- record
>
>
set myVar to {1} as list
>
set myVar to myVar & {myRec:"rec"}
>
class of myVar
>
-- list
>
>
So: empty list gets coerced to record, non-empty list gets record coerced to
>
list. Seems there is at least an exception to the rule of coercing from right
to
>
left...
I guess the empty list is Schrodinger's Cat. Until you observe it, it exists as
a list/record duality.
--
Scott Norton Phone: +1-703-299-1656
DTI Associates, Inc. Fax: +1-703-706-0476
2920 South Glebe Road Internet: email@hidden
Arlington, VA 22206-2768 or email@hidden