Skip to content

Commit 5ed28a7

Browse files
committed
Another 32-bit platform fix
1 parent 9a270cc commit 5ed28a7

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

mypyc/lower/list_ops.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,12 @@ def list_item_ptr(builder: LowLevelIRBuilder, obj: Value, index: Value, line: in
5252
"""
5353
items = list_items(builder, [obj], line)
5454
delta = builder.add(
55-
IntOp(c_pyssize_t_rprimitive, index, Integer(8, c_pyssize_t_rprimitive), IntOp.MUL)
55+
IntOp(
56+
c_pyssize_t_rprimitive,
57+
index,
58+
Integer(PLATFORM_SIZE, c_pyssize_t_rprimitive),
59+
IntOp.MUL,
60+
)
5661
)
5762
return builder.add(IntOp(pointer_rprimitive, items, delta, IntOp.ADD))
5863

0 commit comments

Comments
 (0)