From: Francesc A. <fa...@ca...> - 2006-06-16 19:36:24
|
A Divendres 16 Juny 2006 21:25, Thomas Heller va escriure: > Robert Kern wrote: > > Like how Win64 uses 32-bit longs and 64-bit pointers. And then there's > > signedness. Please don't use Python ints to encode pointers. Holding > > arbitrary pointers is the job of CObjects. > > (Sorry, I'm late in reading this thread. I didn't know there were so many > numeric groups) > > Python has functions to convert pointers to int/long and vice versa:=20 > PyInt_FromVoidPtr() and PyInt_AsVoidPtr(). ctypes uses them, ctypes also > represents addresses as ints/longs. Very interesting. So, may I suggest to use this capability to represent=20 addresses? I think this would simplify things (specially it will prevent to= =20 use ascii/pointer conversions, which are ugly to my mind). Cheers, =2D-=20 >0,0< Francesc Altet =A0 =A0 http://www.carabos.com/ V V C=E1rabos Coop. V. =A0=A0Enjoy Data "-" |