[Python-3000] u'text' as an alias for 'text'?
Lennart Regebro
regebro at gmail.com
Mon Mar 24 09:06:29 CET 2008
On Mon, Mar 24, 2008 at 1:18 AM, Mike Meyer <mwm at mired.org> wrote:
> > under 2.5 or 2.6. This is not possible with 3.0. You can't write 2.5
> > code and run it under 3.0.
>
> I don't think anyone proposed writing 2.5 code to run on 3.0.
I meant to write 2.6, not 2.5.
> It really does appear that, for such a project (and I think two of
> mine - python-xlib & plwm - qualify) 2.5->2.6 and 2.6->3.0 aren't that
> far apart. You can write code for the old version, and run it (with
> suitable preprocessing) on the new version. You can't use features
> available in the new version until everyone is off the old version.
Note how this is libraries with a small set of developers and a well
defined API that gets released on (ir)regular intervals and whos users
use the release. Just the type of project I many times agreed 2to3
will work well on.
> Um, I hate to tell you this, but the vast majority of programmers
> debug a different version of the code than they write, because they
> are using a compiled language. They write in a nice character based
> language like C, but then debug a binary machine code. Yeah, smart
> compilers and debuggers help, by building a mapping from the machine
> code back to the character code, and then using it so it looks like
> you're debugging the character code.
>
> Which brings up a feature request for 2to3/3.0: the ability to leave
> cookies in the 3.0 file that "smart" debuggers can use to help with
> debugging code from 2to3? At the very least, each time a line is
> changed, the ability to add a comment with the original line and the
> file and line number it came from.
A complicated solution for a problem that isn't necessary, and only
solves it if you are using a smart debugger...
--
Lennart Regebro: Zope and Plone consulting.
http://www.colliberty.com/
+33 661 58 14 64
More information about the Python-3000
mailing list