summaryrefslogtreecommitdiff
path: root/Modules/mpzmodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/mpzmodule.c')
-rw-r--r--Modules/mpzmodule.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/Modules/mpzmodule.c b/Modules/mpzmodule.c
index 5ff0801954..d0b9d7f9a9 100644
--- a/Modules/mpzmodule.c
+++ b/Modules/mpzmodule.c
@@ -993,7 +993,9 @@ mpz_mpzcoerce(z)
err_setstr(TypeError, "number coercion (to mpzobject) failed");
return NULL;
} /* mpz_mpzcoerce() */
-
+
+static void mpz_divm();
+
static object *
MPZ_powm(self, args)
object *self;
@@ -1181,7 +1183,7 @@ MPZ_sqrtrem(self, args)
} /* MPZ_sqrtrem() */
-void
+static void
#if __STDC__
mpz_divm(MP_INT *res, const MP_INT *num, const MP_INT *den, const MP_INT *mod)
#else
@@ -1544,7 +1546,7 @@ static struct methodlist mpz_methods[] = {
{"hex", mpz_hex},
{"oct", mpz_oct},
#endif /* def MPZ_CONVERSIONS_AS_METHODS */
- {"binary", mpz_binary},
+ {"binary", (object * (*) (object *, object *)) mpz_binary},
{NULL, NULL} /* sentinel */
};
@@ -1639,11 +1641,11 @@ static typeobject MPZtype = {
sizeof(mpzobject), /*tp_size*/
0, /*tp_itemsize*/
/* methods */
- mpz_dealloc, /*tp_dealloc*/
+ (void (*) (object *)) mpz_dealloc, /*tp_dealloc*/
0, /*tp_print*/
- mpz_getattr, /*tp_getattr*/
+ (object * (*)(object *, char *)) mpz_getattr, /*tp_getattr*/
0, /*tp_setattr*/
- mpz_compare, /*tp_compare*/
+ (int (*) (object *, object *)) mpz_compare, /*tp_compare*/
mpz_repr, /*tp_repr*/
&mpz_as_number, /*tp_as_number*/
};