--- qtwebkit-5.212.0-alpha2/Source/JavaScriptCore/generate-bytecode-files (original)
+++ qtwebkit-5.212.0-alpha2/Source/JavaScriptCore/generate-bytecode-files (refactored)
@@ -91,7 +91,7 @@
try:
return open(path, mode)
except IOError as e:
- print "I/O error opening {0}, ({1}): {2}".format(path, e.errno, e.strerror)
+ print("I/O error opening {0}, ({1}): {2}".format(path, e.errno, e.strerror))
exit(1)
def hashFile(file):
@@ -165,7 +165,7 @@
try:
bytecodeSections = json.load(bytecodeFile, encoding = "utf-8")
except:
- print "Unexpected error parsing {0}: {1}".format(bytecodeJSONFile, sys.exc_info())
+ print("Unexpected error parsing {0}: {1}".format(bytecodeJSONFile, sys.exc_info()))
if bytecodeHFilename:
bytecodeHFile.write(hFileHashString)
--- qtwebkit-5.212.0-alpha2/Source/JavaScriptCore/generate-bytecode-files.old 2018-07-16 10:18:49.850000000 +0000
+++ qtwebkit-5.212.0-alpha2/Source/JavaScriptCore/generate-bytecode-files 2018-07-16 10:22:35.290000000 +0000
@@ -157,10 +157,10 @@
exit(0)
if bytecodeHFilename:
- bytecodeHFile = openOrExit(bytecodeHFilename, "wb")
+ bytecodeHFile = openOrExit(bytecodeHFilename, "w")
if initASMFileName:
- initBytecodesFile = openOrExit(initASMFileName, "wb")
+ initBytecodesFile = openOrExit(initASMFileName, "w")
try:
bytecodeSections = json.load(bytecodeFile, encoding = "utf-8")