]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
* Objects/{int,long,float}object.c, Include/object.h,
authorGuido van Rossum <guido@python.org>
Tue, 9 Aug 1994 13:21:54 +0000 (13:21 +0000)
committerGuido van Rossum <guido@python.org>
Tue, 9 Aug 1994 13:21:54 +0000 (13:21 +0000)
Python/bltinmodule.c: mods by Andrew Kuchling to implement
pow(x,y,z) == pow(x,y)%z, but without incurring overflow

Include/object.h

index 416ca77964f6c2539f95825121dafa73521213ea..cf10ec518177851dfc4d7661217702801c3f2b24 100644 (file)
@@ -135,6 +135,7 @@ method blocks.
 
 typedef object * (*unaryfunc) PROTO((object *));
 typedef object * (*binaryfunc) PROTO((object *, object *));
+typedef object * (*ternaryfunc) PROTO((object *, object *, object *));
 typedef int (*inquiry) PROTO((object *));
 typedef int (*coercion) PROTO((object **, object **));
 typedef object *(*intargfunc) PROTO((object *, int));
@@ -150,7 +151,7 @@ typedef struct {
        binaryfunc nb_divide;
        binaryfunc nb_remainder;
        binaryfunc nb_divmod;
-       binaryfunc nb_power;
+       ternaryfunc nb_power;
        unaryfunc nb_negative;
        unaryfunc nb_positive;
        unaryfunc nb_absolute;