a question on python dict
Lawrence D'Oliveiro
ldo at geek-central.gen.new_zealand
Sun Dec 31 22:24:59 EST 2006
In message <Xns98AA4BE8CF35Ctim111one at 216.196.97.136>, Tim Peters wrote:
> [Tim Peters]
>>>>> You should also note that copying a dict key or value (no matter of
>>>>> what type) consists in its entirety of copying one machine address (a
>>>>> 4- or 8-byte pointer, depending on platform).
>
> [Lawrence D'Oliveiro]
>>>> Actually, no. It also consists of updating reference counts as well.
>
> [Tim Peters]
>>> Not in context: dict resizing is refcount-neutral...
>
> [Lawrence D'Oliveiro]
>> The question wasn't about resizing, it was about "copying a dict key or
>> value".
>
> Then you misunderstood the OP. He was asking about dict resizing:
Which is not what you were talking about, in the part of your posting that I
was responding to (above).
More information about the Python-list
mailing list