Proposed PEP: Treating Builtins as Constants in the Standard Library

Robert Brewer fumanchu at amor.org
Sat Apr 17 20:53:51 EDT 2004


Raymond Hettinger wrote a new PEP proposal:
> For each module in the standard library, add a pair of lines near
> the near of the code::

I think you meant, "near the end of the code". ;)

> Q. Why not make this a public module so that users can 
> optimize builtins
>    or builtins and globals in their own code?
> 
> A. The ASPN recipe [2]_ is provided for this purpose.  It 
> takes a modicum
>    of skill to use correctly and not inadvertently tranform a 
> non-constant.

HmmmmMmmmm..yeah... but then so does your garden-variety "while True:"
loop. I for one would hate reusing the ASPN one when there's one not
only already written but already loaded(!). And...as the builtin
matures, I doubt the cookbook recipe will keep pace.

Meh. I'm going to have to think more about that one.


Robert Brewer
MIS
Amor Ministries
fumanchu at amor.org




More information about the Python-list mailing list