Globals/compatibility_fixes.py

changeset 4566
a2e8f3c420ec
parent 4543
2e6a880670e9
child 4691
0fe41214fdd6
equal deleted inserted replaced
4564:a6480863adfb 4566:a2e8f3c420ec
282 return codecs.decode(txt, self.__encoding) 282 return codecs.decode(txt, self.__encoding)
283 283
284 # Inject into the __builtin__ dictionary 284 # Inject into the __builtin__ dictionary
285 __builtin__.open = open 285 __builtin__.open = open
286 286
287 if __name__ == '__main__':
288 fp = open('compatibility_fixes.py', encoding='latin1')
289 print(fp.read())
290 fp.close()
291
292 with open('compatibility_fixes.py', encoding='UTF-8') as fp:
293 rlines = fp.readlines()
294 print(rlines[-1])
295
296 # 287 #
297 # eflag: FileType = Python2 288 # eflag: FileType = Python2
298 # eflag: noqa = M702 289 # eflag: noqa = M702

eric ide

mercurial