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 josh.r
Recipients bgailer, docs@python, josh.r, martin.panter
Date 2014-04-17.10:43:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1397731396.33.0.0205968308226.issue21279@psf.upfronthosting.co.za>
In-reply-to
Content
For the record, I have intentionally used bytes.maketrans to make translation table for str.translate for precisely this reason; it's much faster to look up a ordinal in a bytes object than in a dictionary. Before the recent (partial) patch for str.translate performance (#21118), this was a huge improvement if you only needed to worry about latin-1 characters (though encoding to latin-1, using bytes.translate, then decoding again was still faster). It's still faster than using a dictionary even with the patch from #21118, but it's not nearly as significant.
History
Date User Action Args
2014-04-17 10:43:16josh.rsetrecipients: + josh.r, bgailer, docs@python, martin.panter
2014-04-17 10:43:16josh.rsetmessageid: <1397731396.33.0.0205968308226.issue21279@psf.upfronthosting.co.za>
2014-04-17 10:43:16josh.rlinkissue21279 messages
2014-04-17 10:43:16josh.rcreate