--- a/js2py/internals/byte_trans.py 2018-09-14 22:37:33.103841506 +0530
+++ b/js2py/internals/byte_trans.py 2018-09-14 22:40:16.219848573 +0530
@@ -717,20 +717,19 @@ def main():
#
# }
a.emit(d)
- print a.declared_vars
- print a.exe.tape
- print len(a.exe.tape)
+ print(a.declared_vars)
+ print(a.exe.tape)
+ print(len(a.exe.tape))
a.exe.compile()
def log(this, args):
- print args[0]
+ print(args[0])
return 999
- print a.exe.run(a.exe.space.GlobalObj)
-
+ print(a.exe.run(a.exe.space.GlobalObj))
if __name__=='__main__':
main()
--- a/js2py/internals/speed.py 2018-09-14 22:40:29.707849158 +0530
+++ b/js2py/internals/speed.py 2018-09-14 22:43:42.123857495 +0530
@@ -47,7 +47,7 @@ t = []
Type = None
try:
- print timeit(
+ print(timeit(
"""
t.append(4)
@@ -55,6 +55,6 @@ t.pop()
-""", "from __main__ import X,Y,namedtuple,array,t,add,Type, izip", number=1000000)
+""", "from __main__ import X,Y,namedtuple,array,t,add,Type, izip", number=1000000))
except:
- raise
\ No newline at end of file
+ raise
--- a/js2py/internals/constructors/jsfunction.py 2018-09-14 22:45:43.027862734 +0530
+++ b/js2py/internals/constructors/jsfunction.py 2018-09-14 22:47:02.891866195 +0530
@@ -66,5 +66,5 @@ def _eval(this, args):
return executable_code(code_str, args.space, global_context=True)()
def log(this, args):
- print ' '.join(map(to_string, args))
- return undefined
\ No newline at end of file
+ print(' '.join(map(to_string, args)))
+ return undefined
--- a/js2py/test_internals.py 2018-09-14 22:47:17.159866813 +0530
+++ b/js2py/test_internals.py 2018-09-14 22:47:46.339868077 +0530
@@ -6,4 +6,4 @@ x = r'''
function g() {var h123 = 11; return [function g1() {return h123}, new Function('return h123')]}
g()[1]()
'''
-print seval.eval_js_vm(x)
+print(seval.eval_js_vm(x))