inliner:自动内联 python 方法

时间:2021-05-29 19:30:53
【文件属性】:
文件名称:inliner:自动内联 python 方法
文件大小:7KB
文件格式:ZIP
更新时间:2021-05-29 19:30:53
Python Inliner 内联 Python 函数调用。 的概念证明 from inliner import inline @inline def add_stuff(x, y): return x + y def add_lots_of_numbers(): results = [] for i in xrange(10): results.append(add_stuff(i, i+1)) 在上面的代码中,add_lots_of_numbers 函数被转换成这样: def add_lots_of_numbers(): results = [] for i in xrange(10): results.append(i + i + 1)
【文件预览】:
inliner-master
----tests()
--------__init__.py(19B)
----test_func.py(417B)
----LICENSE(1KB)
----runner.py(49B)
----readme.md(556B)
----inliner()
--------utils.py(2KB)
--------searcher.py(344B)
--------__init__.py(35B)
--------transformer.py(851B)
--------import_hook.py(1KB)
--------transformers()

网友评论