Comment on A function decorator that rewrites the bytecode to enable goto in PythonparentComments−loeg4ySurely the ten+ year Python 3-is-incompatible-with-2 saga was also a mistake.−eru4yThey could have tried to handle this in a better way, but some incompatible changes were useful and probably necessary.Perhaps files could have declared at the top whether they were Python 2 or 3, and the pyc could have been kept as compatible as possible?−masklinn4yWouldn’t have been very useful, there were not that many incompatible syntactic changes you could not ignore or paper over (string literals were the main issue until u”” was restored) and it would not have helped any with the semantic & api changes.
Comments
Surely the ten+ year Python 3-is-incompatible-with-2 saga was also a mistake.
They could have tried to handle this in a better way, but some incompatible changes were useful and probably necessary.
Perhaps files could have declared at the top whether they were Python 2 or 3, and the pyc could have been kept as compatible as possible?
Wouldn’t have been very useful, there were not that many incompatible syntactic changes you could not ignore or paper over (string literals were the main issue until u”” was restored) and it would not have helped any with the semantic & api changes.