Amaury Forgeot d'Arc <[email protected]> added the comment:

No, please revert this, in the official API those functions return PyObject:
    PyAPI_FUNC(PyObject *) PyInt_FromLong(long);

And it would not change anything, except maybe a pointer cast.
The point here is that we need cpyext to allocate a PyIntObject structure, i.e. 
call 
"int_realize()", and this is why the solid_base is important.

PyInt_Check(obj) && ((PyIntObject*)obj)->ob_ival
is the best test.

________________________________________
PyPy bug tracker <[email protected]>
<https://bugs.pypy.org/issue1621>
________________________________________
_______________________________________________
pypy-issue mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-issue

Reply via email to