A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2007-December/075531.html below:

[Python-Dev] Non-string keys in namespace dicts

[Python-Dev] Non-string keys in namespace dicts [Python-Dev] Non-string keys in namespace dictsGuido van Rossum guido at python.org
Mon Dec 3 19:53:04 CET 2007
On Dec 2, 2007 12:49 PM, Neil Toronto <ntoronto at cs.byu.edu> wrote:
> It turned out not *that* hard to code around for attribute caching, and
> the extra cruft only gets invoked on a cache miss. The biggest problem
> isn't speed - it's that it's possible (though extremely unlikely), while
> testing keys for equality, that a rich compare alters the underlying
> dict. This causes the caching lookup to have to try to get an entry
> pointer again, which could invoke the rich compare, which might alter
> the underlying dict..

How about subclasses of str? These have all the same issues...

> I'm working on making it as fast as the original when the MRO is short.
> Question for Guido: should I roll this into the fastglobals patch?

No, please keep them separate.

-- 
--Guido van Rossum (home page: http://www.python.org/~guido/)
More information about the Python-Dev mailing list

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