On 2006-11-10, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > Marc 'BlackJack' Rintsch wrote: >> Why? Python strings are *byte strings* and bytes have values in the range >> 0..255. Why would you restrict them to ASCII only? > > Because getting an exception when comparing a string with a unicode > string is irritating. > > But I don't insist on my PEP. The example just shows just > another pitfall with Unicode and why I'll advise to any > beginner: Never write text constants that contain non-ascii > chars as simple strings, always make them Unicode strings by > prepending the "u".
That doesn't do any good if you aren't writing them in unicode code points, though. -- Neil Cerutti To succeed in the world it is not enough to be stupid, you must also be well-mannered. --Voltaire -- http://mail.python.org/mailman/listinfo/python-list