summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1995-02-17 15:10:07 (GMT)
committerGuido van Rossum <guido@python.org>1995-02-17 15:10:07 (GMT)
commit3a205f7ea02a54b0d0278a166530a1ab6e5ed84d (patch)
tree39b6d5d89ecf0921512ad8e08e1946b7ff258468
parentd9dfaf5a3b4f714857f16cf0d2a7637829dcb659 (diff)
downloadcpython-3a205f7ea02a54b0d0278a166530a1ab6e5ed84d.zip
cpython-3a205f7ea02a54b0d0278a166530a1ab6e5ed84d.tar.gz
cpython-3a205f7ea02a54b0d0278a166530a1ab6e5ed84d.tar.bz2
hope to fix DEC Alpha gcc problems by declaring ints instead of longs
-rw-r--r--Python/marshal.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/Python/marshal.c b/Python/marshal.c
index 54cabf6..2176d3c 100644
--- a/Python/marshal.c
+++ b/Python/marshal.c
@@ -121,7 +121,7 @@ w_object(v, p)
object *v;
WFILE *p;
{
- long i, n;
+ int i, n;
if (v == NULL)
w_byte(TYPE_NULL, p);
@@ -147,29 +147,29 @@ w_object(v, p)
float_buf_repr(buf, (floatobject *)v);
n = strlen(buf);
w_byte(TYPE_FLOAT, p);
- w_byte((int)n, p);
- w_string(buf, (int)n, p);
+ w_byte(n, p);
+ w_string(buf, n, p);
}
else if (is_stringobject(v)) {
w_byte(TYPE_STRING, p);
n = getstringsize(v);
- w_long(n, p);
- w_string(getstringvalue(v), (int)n, p);
+ w_long((long)n, p);
+ w_string(getstringvalue(v), n, p);
}
else if (is_tupleobject(v)) {
w_byte(TYPE_TUPLE, p);
n = gettuplesize(v);
- w_long(n, p);
+ w_long((long)n, p);
for (i = 0; i < n; i++) {
- w_object(gettupleitem(v, (int)i), p);
+ w_object(gettupleitem(v, i), p);
}
}
else if (is_listobject(v)) {
w_byte(TYPE_LIST, p);
n = getlistsize(v);
- w_long(n, p);
+ w_long((long)n, p);
for (i = 0; i < n; i++) {
- w_object(getlistitem(v, (int)i), p);
+ w_object(getlistitem(v, i), p);
}
}
else if (is_dictobject(v)) {