long l;
PyObject *rc = 0;
- if (mp_tolong_checked(PFILT_F(me)->m, &l)) goto end;
- rc = PyInt_FromLong(l);
-end:
+ if (!mp_tolong_checked(PFILT_F(me)->m, &l, 0)) rc = PyInt_FromLong(l);
+ else rc = mp_topylong(PFILT_F(me)->m);
return (rc);
}
mp *x = 0;
pgen_event *ev = PGEVENT_EV(me);
int rc = -1;
+ if (!x) NIERR("__del__");
PGEVENT_CHECK(me);
if ((x = getmp(xobj)) == 0) goto end;
mp_drop(ev->m);