summaryrefslogtreecommitdiffstats
path: root/Python/compile.c
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2006-04-10 01:03:32 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2006-04-10 01:03:32 (GMT)
commitb183a25c29e45b8aa4a07ddd6223e6bf12c43309 (patch)
tree0b8ecb7e7a04fd462084d946b7100d5626493d25 /Python/compile.c
parent6974a51d1a1eb73827aa1393a65c1f6fac256d0e (diff)
downloadcpython-b183a25c29e45b8aa4a07ddd6223e6bf12c43309.zip
cpython-b183a25c29e45b8aa4a07ddd6223e6bf12c43309.tar.gz
cpython-b183a25c29e45b8aa4a07ddd6223e6bf12c43309.tar.bz2
Fix some warnings on HP-UX when using cc/aCC
Diffstat (limited to 'Python/compile.c')
-rw-r--r--Python/compile.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 3f73255..ae4c850 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -4089,7 +4089,7 @@ assemble_lnotab(struct assembler *a, struct instr *i)
{
int d_bytecode, d_lineno;
int len;
- char *lnotab;
+ unsigned char *lnotab;
d_bytecode = a->a_offset - a->a_lineno_off;
d_lineno = i->i_lineno - a->a_lineno;
@@ -4112,7 +4112,8 @@ assemble_lnotab(struct assembler *a, struct instr *i)
if (_PyString_Resize(&a->a_lnotab, len) < 0)
return 0;
}
- lnotab = PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
+ lnotab = (unsigned char *)
+ PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
for (j = 0; j < ncodes; j++) {
*lnotab++ = 255;
*lnotab++ = 0;
@@ -4133,7 +4134,8 @@ assemble_lnotab(struct assembler *a, struct instr *i)
if (_PyString_Resize(&a->a_lnotab, len) < 0)
return 0;
}
- lnotab = PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
+ lnotab = (unsigned char *)
+ PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
*lnotab++ = 255;
*lnotab++ = d_bytecode;
d_bytecode = 0;
@@ -4150,7 +4152,8 @@ assemble_lnotab(struct assembler *a, struct instr *i)
if (_PyString_Resize(&a->a_lnotab, len * 2) < 0)
return 0;
}
- lnotab = PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
+ lnotab = (unsigned char *)
+ PyString_AS_STRING(a->a_lnotab) + a->a_lnotab_off;
a->a_lnotab_off += 2;
if (d_bytecode) {