Browse Source

tests/micropython/viper_cond: Add test for large int as bool.

pull/4021/head
Damien George 6 years ago
parent
commit
49529f22d4
  1. 8
      tests/micropython/viper_cond.py
  2. 1
      tests/micropython/viper_cond.py.exp

8
tests/micropython/viper_cond.py

@ -23,3 +23,11 @@ def g():
if y:
print("y", y)
g()
# using an int as a conditional that has the lower 16-bits clear
@micropython.viper
def h():
z = 0x10000
if z:
print("z", z)
h()

1
tests/micropython/viper_cond.py.exp

@ -1,3 +1,4 @@
not x False
x True
y 1
z 65536

Loading…
Cancel
Save