On Jun 4, 2009, at 3:25 AM, Hendrik van Rooyen wrote:

A can is like a pickle, in that it is a string, but anything
can be canned.
Unlike a pickle, a can cannot leave the process, though,
unless the object it points to lives in shared memory.

If you have any interest, contact me and I will
send you the source.

Sounds like di(), which can be written:

import _ctypes
di = _ctypes.PyObj_FromPtr

def can(o): return str(id(o))
def uncan(s): return di(int(s))

http://www.friday.com/bbum/2007/08/24/python-di/

-Miles

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to