
Sept. 20, 2006
7:51 a.m.
Holger Joukl wrote:
the type registration of LongElement in _registerPyTypes in objectify.pyx (line 833 in my not totally up-to-date 1.1 checkout) should be changed from
pytype = PyType('long', None, LongElement) to pytype = PyType('long', long, LongElement)
to activate its actual usefulness.
Funny I never noticed that before.
You didn't notice it because it is not used. As Python's int() accepts both ints and longs, there is no use in parsing values with both. It is only used for resolving the 'long' pytype hint, not for parsing longs. That's why the type check function is None. Stefan