summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1997-05-13 18:00:44 (GMT)
committerGuido van Rossum <guido@python.org>1997-05-13 18:00:44 (GMT)
commitde8d6d73fbab18461ff9d9ff665f1302062af5aa (patch)
tree6c43503ad7457d907f61c550bf2e92b12c345255 /Modules
parentc5d14a65a77bce31e1dafb547b2d680a42cf7e99 (diff)
downloadcpython-de8d6d73fbab18461ff9d9ff665f1302062af5aa.zip
cpython-de8d6d73fbab18461ff9d9ff665f1302062af5aa.tar.gz
cpython-de8d6d73fbab18461ff9d9ff665f1302062af5aa.tar.bz2
Use compile-time test for 64-bit hardware instead of run-time test.
This silences some compilers.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/cPickle.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/Modules/cPickle.c b/Modules/cPickle.c
index abe7d67..56a0fac 100644
--- a/Modules/cPickle.c
+++ b/Modules/cPickle.c
@@ -675,7 +675,11 @@ save_int(Picklerobject *self, PyObject *args) {
long l = PyInt_AS_LONG((PyIntObject *)args);
int len = 0;
- if (!self->bin || sizeof(long) == 8 && (l >> 32)) {
+ if (!self->bin
+#if SIZEOF_LONG > 4
+ || (l >> 32)
+#endif
+ ) {
/* Save extra-long ints in non-binary mode, so that
we can use python long parsing code to restore,
if necessary. */
@@ -3869,6 +3873,10 @@ initcPickle() {
/****************************************************************************
$Log$
+ Revision 2.6 1997/05/13 18:00:44 guido
+ Use compile-time test for 64-bit hardware instead of run-time test.
+ This silences some compilers.
+
Revision 2.5 1997/05/07 17:46:13 guido
Instead of importing graminit.h whenever one of the three grammar 'root'
symbols is needed, define these in Python.h with a Py_ prefix.