Gabriel Genellina wrote:
En Sun, 26 Oct 2008 12:13:08 -0200, Christian Heimes <[EMAIL PROTECTED]> escribió:

?????? wrote:
Any ideas?
 Code 1:
 from __future__ import print_function, unicode_literals
import sys
print(type('HELLO, WORLD!'), file=sys.stderr)

You have to do each future import in a separate line:

 >>> from __future__ import unicode_literals
 >>> from __future__ import print_function
 >>> print(type(""), file=sys.stderr)
<type 'unicode'>

That's a bug, isn't it? The language reference explicitely allows it:
http://docs.python.org/reference/simple_stmts.html#future-statements

Yes, and Benjamin Peterson already submitted a patch because of this thread.
http://bugs.python.org/issue4209

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to