[Python-ideas] string codes & substring equality

Chris Angelico rosuav at gmail.com
Thu Nov 28 23:59:36 CET 2013


On Fri, Nov 29, 2013 at 9:56 AM, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:
> spir wrote:
>>
>> Is it weird to consider a .code(i) string method?
>
>
> Another approach would be to keep a cache of single-char
> strings, like we do for small integers.

Would you really keep a cache of 1114112 string objects around? Seems
a bit of overkill.

ChrisA


More information about the Python-ideas mailing list