def test():
global xxx
if 1: # reflect self
c0 = compile(TESTCODE, '', 'exec')
t0 = codetree(c0); s = repr(t0); t0 = eval(s); c = t0.compile()
t0 = codetree(c); s = repr(t0)
print 'exec'; exec(c0, globals()); exec(c, globals()); print dis.dis(c)
# compile, expand, recompile, exec
if PYVERSION == 'py2x': print s
if 0: print s
else:
t = t0.py3to2() if hasattr(t0, 'py3to2') else t0; xxx = t; s = repr(t)
评论列表
文章目录