homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients pitrou, serhiy.storchaka, vstinner
Date 2013年04月19日.20:18:53
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1366402733.56.0.391953444227.issue17742@psf.upfronthosting.co.za>
In-reply-to
Content
_PyBytesWriter and _PyUnicodeWriter have differen use cases. While _PyUnicodeWriter used primary in formatter where resulting size is rarely known and reallocation in decoders usually caused by widening result, _PyBytesWriter is used only in decoders where we usually can estimate a result size or it's upper bound. Resizing happened only in exceptional cases, when error handler called.
The patch contains a special case for writing only one bytes object. This is very unlikely case. It happened only when an encoded string contains only one illegal character. I think this case is not worth a complication and
obfuscation of the code. I think we should drop readonly attribute and a piece of the code (which looks buggy for me anyway).
History
Date User Action Args
2013年04月19日 20:18:53serhiy.storchakasetrecipients: + serhiy.storchaka, pitrou, vstinner
2013年04月19日 20:18:53serhiy.storchakasetmessageid: <1366402733.56.0.391953444227.issue17742@psf.upfronthosting.co.za>
2013年04月19日 20:18:53serhiy.storchakalinkissue17742 messages
2013年04月19日 20:18:53serhiy.storchakacreate

AltStyle によって変換されたページ (->オリジナル) /