Skip to content

Commit c4ed17f

Browse files
v923zdpgeorge
authored andcommitted
tests/cpydiff: Add test for array constructor with overflowing value.
1 parent 3ab8806 commit c4ed17f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
"""
2+
categories: Modules,array
3+
description: Overflow checking is not implemented
4+
cause: MicroPython implements implicit truncation in order to reduce code size and execution time
5+
workaround: If CPython compatibility is needed then mask the value explicitly
6+
"""
7+
import array
8+
9+
a = array.array("b", [257])
10+
print(a)

0 commit comments

Comments
 (0)