Message6432

Author amak
Recipients amak, yyamano
Date 2011-03-12.14:16:07
SpamBayes Score 1.885409e-08
Marked as misclassified No
Message-id <1299939367.64.0.0842761697428.issue1707@psf.upfronthosting.co.za>
In-reply-to
Content
Another point to mention is that the reason for this difference in behaviour is because cpython uses UCS-2 for character representation, whereas java (and thus jython) uses UTF-16.

"\udeee" *is* a valid code point in UCS-2: it just doesn't represent anything. This is why cpython does not complain.

http://www.unicode.org/charts/PDF/UDC00.pdf

Jython's behaviour is arguably more correct in this case. 

Also cpython, because it uses UCS-2, cannot represent characters outside the "Basic Multilingual Plane", but jython, because it uses UTF-16, can.

http://en.wikipedia.org/wiki/UTF-16/UCS-2
History
Date User Action Args
2011-03-12 14:16:07amaksetmessageid: <1299939367.64.0.0842761697428.issue1707@psf.upfronthosting.co.za>
2011-03-12 14:16:07amaksetrecipients: + amak, yyamano
2011-03-12 14:16:07amaklinkissue1707 messages
2011-03-12 14:16:07amakcreate