circuitpython/tests/micropython/viper_import.py

16 lines
184 B
Python
Raw Normal View History

# test import within viper function
2021-03-15 09:57:36 -04:00
@micropython.viper
def f():
import micropython
2021-03-15 09:57:36 -04:00
print(micropython.const(1))
from micropython import const
2021-03-15 09:57:36 -04:00
print(const(2))
2021-03-15 09:57:36 -04:00
f()