On Tue, Jul 23, 2013 at 1:17 AM, Jim Mooney <cybervigila...@gmail.com>wrote:

> On 23 July 2013 00:40, Steven D'Aprano <st...@pearwood.info> wrote:
>
>>
>> No no no, a thousand times no!!! IDs are just numeric IDs, that is all,
>> like your social security number or driver's licence number. Don't think of
>> them as having any meaning at all, except that they are unique during the
>> lifetime of the object.
>>
>
> Okay, ID stands for a location fixed until the object disappears, but we
> don't know where that location is. But what about object offsets from self?
> Is the beginning of self.spam always the same distance from the beginning
> of self.eggs? Or can I just forget the hard ground of assembler-metaphors
> entirely as I float off into abstractville? I guess the fixed lengths I
> kept getting on re-runs were coincidental but not to be relied on.
>

As Steven said: they are NOT locations, they are IDs.  There is no distance
involved.  You CAN find the size of an object, and you can find its
location in memory (but you really shouldn't bother, or rely on it) but
neither of those things has any particular relation to the ID, except
accidentally.
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to