Python 3 put-downs: What's the point?

Steven D'Aprano steve at REMOVE-THIS-cybersource.com.au
Mon Jul 5 20:22:06 EDT 2010


On Mon, 05 Jul 2010 14:32:13 -0500, Tim Chase wrote:

> On 07/05/2010 02:50 AM, Gregor Horvath wrote:
>> Am Sun, 04 Jul 2010 18:51:54 -0500
>> schrieb Tim Chase<python.list at tim.thechases.com>:
>>
>>> I think it's the same venting of frustration that caused veteran VB6
>>> developers to start calling VB.Net "Visual Fred" -- the language was
>>> too different and too non-backwards-compatible.
>>>
>>>
>> VB6 ->  VB.NET and Python 2 ->  3 is not a valid comparison.
>>
>> VB6 and VB.NET are totally different languages and technologies, with
>> some similarity in syntax. This is not true for Python 2->3. This is an
>> healthy organic language growth, not an abandon of a language.
> 
> The quintessential example is Py3's breaking of Hello World. It's a
> spectrum of language changes -- Visual Fred just happens to be MUCH
> further down the same spectrum having more dramatic changes.  Only a
> subset of $OLD_VER (whether Py2 or VB6) code will run unmodified under
> $NEW_VER (whether Py3 or VB.Net).

The same holds for older versions of Python to Python 2.5 or 2.6, it's 
just that you have to work harder to find the incompatibilities. Try 
running this under later versions:

[steve at sylar ~]$ python2.0
Python 2.0.1 (#1, Jan 14 2010, 15:43:17)
[GCC 4.1.2 20070925 (Red Hat 4.1.2-27)] on linux2
Type "copyright", "credits" or "license" for more information.
>>> None = "Hello world"
>>> print None
Hello world


> It just happens that the subset for
> Python is considerably larger than the subset for VB (and Python's
> conversion tools seem a little more useful than VB's, IMHO).  IIRC,
> neither raw VB6 nor Py2 byte-code will run raw in the new environment
> (old VB .exe files don't make use of .Net libraries/CLR, nor do Py2 .pyc
> files run under Py3) 

Python byte-code has never been compatible across minor version numbers, 
let alone major ones.



-- 
Steven



More information about the Python-list mailing list