Message31811
>BTW, even the official document of Python2.4, chapter "7.3.2.1 Built-in
> Codecs", mentions that the:
> PyObject* PyUnicode_DecodeUTF16( const char *s, int size, const char
> *errors, int *byteorder)
> can "switches according to all byte order marks (BOM) it finds in the
> input data. BOMs are not copied into the resulting Unicode string". I
> don't know whether it is the BOM-less decoder we talked for long time.
This seems to be wrong. Looking at the source code (Objects/unicodeobjects.c) reveals that only the first BOM is skipped.
|
|
| Date |
User |
Action |
Args |
| 2007-08-23 14:53:09 | admin | link | issue1701389 messages |
| 2007-08-23 14:53:09 | admin | create | |
|