实现了一个新的sys.atexit函数,用于注册函数后在主脚本结束时执行。它可以通过配置MICROPY_PY_SYS_ATEXIT,默认情况下禁用。
它与CPython不兼容,而是可以根据需要用于实现CPython兼容的“atexit”模块(类似于sys.print_exception 如何用于实现“traceback”模块的功能)。
https://github.com/micropython/micropyt ... 0828369bd3
mpy增加新的sys.atexit功能
-
- 随机主题
- 回复总数
- 阅读次数
- 最新文章
-
- 5回复总数
- 2031 阅读次数
- 最新文章 由 slotg
2020年 7月 29日 21:48
-
- 1回复总数
- 1049 阅读次数
- 最新文章 由 shaoziyang
2020年 7月 29日 08:59
-
- 2回复总数
- 1031 阅读次数
- 最新文章 由 shaoziyang
2020年 7月 29日 09:24