summaryrefslogtreecommitdiffstats
path: root/Objects/longobject.c
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2001-06-13 20:45:17 (GMT)
committerTim Peters <tim.peters@gmail.com>2001-06-13 20:45:17 (GMT)
commit9cb0c38fff05776f598ebfb67a60abc3bff629e2 (patch)
tree0d43a57fb2ce04040098972b05fd4efd47dc32ed /Objects/longobject.c
parent42107c5a0f5f6dd90c0f38afca45ac548b385750 (diff)
downloadcpython-9cb0c38fff05776f598ebfb67a60abc3bff629e2.zip
cpython-9cb0c38fff05776f598ebfb67a60abc3bff629e2.tar.gz
cpython-9cb0c38fff05776f598ebfb67a60abc3bff629e2.tar.bz2
PyLong_As{Unsigned,}LongLong: fiddled final result casting.
Diffstat (limited to 'Objects/longobject.c')
-rw-r--r--Objects/longobject.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/longobject.c b/Objects/longobject.c
index 615d497..3c22470 100644
--- a/Objects/longobject.c
+++ b/Objects/longobject.c
@@ -572,7 +572,7 @@ PyLong_AsLongLong(PyObject *vv)
(PyLongObject *)vv, (unsigned char *)&bytes,
SIZEOF_LONG_LONG, IS_LITTLE_ENDIAN, 1);
- return (LONG_LONG)(res < 0 ? res : bytes);
+ return res < 0 ? (LONG_LONG)res : bytes;
}
/* Get a C unsigned LONG_LONG int from a long int object.
@@ -594,7 +594,7 @@ PyLong_AsUnsignedLongLong(PyObject *vv)
(PyLongObject *)vv, (unsigned char *)&bytes,
SIZEOF_LONG_LONG, IS_LITTLE_ENDIAN, 0);
- return (unsigned LONG_LONG)(res < 0 ? res : bytes);
+ return res < 0 ? (unsigned LONG_LONG)res : bytes;
}
#undef IS_LITTLE_ENDIAN