Commit 0de6815e authored by Paul Sokolovsky's avatar Paul Sokolovsky Committed by Damien George

tests/extmod/uctypes_ptr_le: Test int() operation on a pointer field.

parent 9d864bde
......@@ -22,6 +22,9 @@ buf = addr.to_bytes(uctypes.sizeof(desc), "little")
S = uctypes.struct(uctypes.addressof(buf), desc, uctypes.LITTLE_ENDIAN)
print(addr == int(S.ptr))
print(addr == int(S.ptr2))
print(S.ptr[0])
assert S.ptr[0] == ord("0")
print(S.ptr[1])
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment