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/2004-April/044468.html below:

[Python-Dev] PEP 329: Treating Builtins as Constants in

[Python-Dev] PEP 329: Treating Builtins as Constants inJewett, Jim J jim.jewett at eds.com
Tue Apr 20 11:58:44 EDT 2004
Brett Cannon wrote:

> ``foo = len(x)`` which loads len (global), loads x (local), 
> calls len, and then stores into foo (local).  ...
> storing built-ins into the local namespace to skip having 
> to try load from the global namespace, fail, and then 
> check the built-in namespace 

An in-between option would be to steal an idea from Jython,
and to make (some?) namespace dictionaries different from 
regular dictionaries. Not only do we know what sorts of keys
are possible, we almost know what every key is at compile time.

-jJ

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