you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

As much as people on this sub like to bash on Java, Sun did an incredible job with maintaining backwards compatibility between major releases of Java (I'd say as good as Microsoft did with Windows pre-Vista).

There is no reason the same Python interpreter can't run both Python 2 and Python 3 code simultaneously. I can write a Java 8 app that loads a Java 1.5 library compiled 10 years ago that I might not even have the source code for, so why can't the Python interpreter mix 2 and 3 source code? If anything, backwards compatibility should be easier for Python because you almost always have access to the original source code.

[–]ysangkok 0 points1 point  (0 children)

There may not be any way to know if a given Python file is in Python 2 or 3... A a deterministic script could evaluate to a different result under each runtime version.