Converting python object reference to int and back
tjreedy at udel.edu
Sun Sep 8 00:20:04 CEST 2002
"Ahmad Baitalmal" <ahmad at NOSPAMbitbuilder.com> wrote in message
news:3D79AC95.1000000 at NOSPAMbitbuilder.com...
> I need to keep references to python objects in a tree control's
This is what Python does for you behind the scenes, automatically,
without error, every time you assign abject to a name or slot.
> The items can hold an integer as data.
> How can I get an id (pointer/reference) from a python object and
> get that object back using that integer?
You almost certainly do not want to do this since it amounts to
duplicating, in a clumsy way, what the interpreter already does for
Terry J. Reedy
More information about the Python-list