Beispiel #1
0
// Divmod returns the result of the Python "divmod(n, obj)".
//
// Return value: New Reference.
func (n *NumberProtocol) Divmod(obj *Base) (*Base, error) {
	ret := C.PyNumber_Divmod(cnp(n), obj.c())
	return obj2ObjErr(ret)
}
Beispiel #2
0
// Divmod returns the result of the Python "divmod(n, obj)".
//
// Return value: New Reference.
func (n *NumberProtocol) Divmod(obj Object) (Object, error) {
	ret := C.PyNumber_Divmod(cnp(n), c(obj))
	return obj2ObjErr(ret)
}