Python 3.0

Python has some good news: Python Enhancement Proposal 3000 (PEP 3000) states that the Py3k project will lead to a new version of Python that will no longer be compatible with 2.x.

The original PEP 3000 was written in April 2006, and since then, developers have been constantly improving the language. The PEP 3000 states that Python 3.0 will break backward compatibility with Python 2.x.

There is no requirement that Python 2.6 code will run unmodified on Python 3.0. Not even a subset. (Of course, there will be a tiny subset, but it will be missing major functionality.)

Python 2.6 will support forward compatibility in the following two ways:

  • It will support a “Py3k warnings mode” which will warn dynamically (i.e. at runtime) about features that will stop working in Python 3.0, e.g. assuming that range() returns a list.
  • It will contain backported versions of many Py3k features, either enabled through future statements or simply by allowing old and new syntax to be used side-by-side (if the new syntax would be a syntax error in 2.x).





Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.