New submission from Jim Jewett:

The specialized lookdict_* variants replace themselves with the generic 
lookdict as soon as a non-unicode key is looked up.  

They could reasonably leave the replacement to insertdict (line 819, currently 
assert rather than a replacement), when a non-unicode key is actually inserted 
into the dict. 

While inserts are less common than (all lookups including insert), I see the 
main advantage as reducing the number of duplications of the replacement logic.

----------
components: Interpreter Core
messages: 243969
nosy: Jim.Jewett
priority: normal
severity: normal
status: open
title: lookdict_* give up too soon
type: enhancement

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24275>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to