[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-24 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: backported to 2.5 branch as r61854 -- status: pending -> closed __ Tracker <[EMAIL PROTECTED]> __ __

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-23 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: Committed r61793. Will backport. -- resolution: -> fixed status: open -> pending __ Tracker <[EMAIL PROTECTED]> __

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-22 Thread Walter Dörwald
Walter Dörwald <[EMAIL PROTECTED]> added the comment: The patch looks goog to me now. Go ahead and check it in. -- assignee: doerwalter -> amaury.forgeotdarc __ Tracker <[EMAIL PROTECTED]> ___

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-20 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: The "strange" code is a copy of PyUnicode_DecodeUnicodeEscape. I find it easier to read. And the duplicate lines are likely to be optimized by the compiler. Here is a new version of the patch which: - correctly forbid illegal code point

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-20 Thread Walter Dörwald
Walter Dörwald <[EMAIL PROTECTED]> added the comment: For a wide build, the code if (x <= 0x) *p++ = (Py_UNICODE) x; else { *p++ = (Py_UNIC0DE) x; looks strange. Furthermore with the patch applied Python no longer complains about illegal code

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: The error is not uncatchable; but it is generated while compiling, like a SyntaxError. No bytecode is generated for the input, and the "except" opcode is not run at all. OTOH, there is a bug in PyUnicode_DecodeRawUnicodeEscape(): it sho

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2008-03-17 Thread Sean Reifschneider
Sean Reifschneider <[EMAIL PROTECTED]> added the comment: Can someone comment on this, or bring it up on python-dev if it needs more discussion? -- assignee: -> doerwalter nosy: +doerwalter, jafo priority: -> low __ Tracker <[EMAIL PROTECTED]>

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2007-11-21 Thread Gabriel Genellina
Changes by Gabriel Genellina: -- nosy: +gagenellina __ Tracker <[EMAIL PROTECTED]> __ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue1477] UnicodeDecodeError that cannot be caught in narrow unicode builds

2007-11-20 Thread Sean B. Palmer
New submission from Sean B. Palmer: The following error is uncatchable: >>> try: ur'\U0010' ... except UnicodeDecodeError: pass ... UnicodeDecodeError: 'rawunicodeescape' codec can't decode byte 0x5c in position 0: \U out of range This is in a narrow unicode build: >>> sys.versio