[Python-Dev] Why is nb_inplace_power ternary? (original) (raw)

"Martin v. Löwis" Martin.vonLoewis at hpi.uni-potsdam.de
Fri Feb 9 09:38:56 CET 2007


Brett Cannon schrieb:

Seems reasonable to me. Is the argument of None passed in automatically somewhere?

There are few callers of nb_inplace_power at all (AFAICT, only PyNumber_InPlacePower); in turn, PyNumber_InPlacePower is called with the implicit Py_None always:

The only case I could find where a third argument is non-None is when the builtin pow() is invoked, which then invokes nb_power (but not nb_inplace_power) with three arguments.

Regards, Martin



More information about the Python-Dev mailing list