imaplib: is this really so unwieldy?

Peter J. Holzer hjp-python at hjp.at
Thu May 27 14:02:57 EDT 2021


On 2021-05-26 08:34:28 +1000, Chris Angelico wrote:
> Yes, any given string has a single width, which makes indexing fast.
> The memory cost you're describing can happen, but apart from a BOM
> widening an otherwise-ASCII string to 16-bit, there aren't many cases
> where you'll get a single wide character in a narrow string.

A single emoji in a long English text.

> Usually, if there are any wide characters, there'll be a good number
> of them

Oh, right. People who use emoji usually use a lot of them 😉.

        hp

-- 
   _  | Peter J. Holzer    | Story must make more sense than reality.
|_|_) |                    |
| |   | hjp at hjp.at         |    -- Charles Stross, "Creative writing
__/   | http://www.hjp.at/ |       challenge!"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://mail.python.org/pipermail/python-list/attachments/20210527/4d986ccb/attachment.sig>


More information about the Python-list mailing list