]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-91924: Optimize unicode_check_encoding_errors() (#93200)
authorVictor Stinner <vstinner@python.org>
Thu, 26 May 2022 22:39:49 +0000 (00:39 +0200)
committerGitHub <noreply@github.com>
Thu, 26 May 2022 22:39:49 +0000 (00:39 +0200)
commit5f8c3fb99746b9a7fadd4ec24cc4025b9c5d79d0
tree07570f1aa71c277b9d4f96cf25b50ed10b6d8e3c
parentefc5d37671d2b9f31850a9edaa495fadae038759
gh-91924: Optimize unicode_check_encoding_errors() (#93200)

Avoid _PyCodec_Lookup() and PyCodec_LookupError() for most common
built-in encodings and error handlers to avoid creating a temporary
Unicode string object, whereas these encodings and error handlers are
known to be valid.
Objects/unicodeobject.c