On Wed, Mar 09, 2005, Raymond Hettinger wrote: > [Aahz] >> >> Gee, I just found out I could have used an OrderedDict today. (We're >> using a dict that we're now having to add an auxilliary list to to track >> when keys are added.) (This isn't particularly an argument in favor of >> adding OrderedDict to stdlib, but it's another use case. Each dict key >> contains a dict value; the subkeys from later-added keys are supposed to >> override earlier subkeys. The original implementation relied on subkeys >> being unique, but that doesn't work for our new business requirements.) > > If I read the proposal correctly, order would be determined by when the > key was first encountered. Presumably, that would mean that the related > value would also be the first encountered (not overridden by later-added > keys as dictated by your business requirements). Hmmmmm.... Guess this means we need a PEP! -- Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/ "The joy of coding Python should be in seeing short, concise, readable classes that express a lot of action in a small amount of clear code -- not in reams of trivial code that bores the reader to death." --GvR
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4