+#define IMPLICIT(pre) \
+ static PyObject *pre##meth__implicit(PyObject *me, PyObject *arg) \
+ { \
+ PyObject *x, *rc = 0; \
+ mp *y = MP_NEW; \
+ if (!PyArg_ParseTuple(arg, "O:_implicit", &x)) goto end; \
+ y = implicit##pre(x); \
+ if (!y) TYERR("can't convert implicitly to " #pre); \
+ rc = pre##_pywrap(y); \
+ end: \
+ return (rc); \
+ }
+IMPLICIT(mp)
+IMPLICIT(gf)
+#undef IMPLICIT
+