[REBOL] Re: TUPLE! DATA-MODEL & OTHER VALUES
From: carl:cybercraft at: 13-Jun-2001 21:00
On 13-Jun-01, Joel Neely wrote:
> Hi, again, Holger,
> Holger Kruse wrote:
[snip]
>> Look at the difference:
>>
>> Series:
>>
>> a: [1 2 3]
>> b: a
>> a/1: 0 ;Changes the data shared by 'a and 'b.
>> a
>> == [0 2 3]
>> b
>> == [0 2 3]
>>
>> Tuple:
>>
>> a: 1.2.3
>> b: a
>> a/1: 0 ;Changes 'a only. 'a and 'b do not share data.
>> a
>> == 0.2.3
>> b
>> == 1.2.3
> If you'll just clarify whether you meant that
> "The tuple in 'a has been modified."
> or
> "The tuple in 'a has been replaced."
> you'll put to rest an issue that has consumed several hours
> (and quite a few gallons of virtual ink!) the past couple of
> weeks. ;-)
Because tuples are like integers "simple" (to use Holger's term), I
have a feeling the answer is that it makes not a jot of difference to
the REBOL programmer. But modified seems the most likely as it'd
save on garbage collection.
> -jn-
> ------------------------------------------------------------
> "Programming languages: compact, powerful, simple ...
> Pick any two!" joel'dot'neely'at'fedex'dot'com
> ------------------------------------------------------------
--
Carl Read
[carl--cybercraft--co--nz]