[Python-Dev] AST optimizer implemented in Python

Chris Angelico rosuav at gmail.com
Sun Aug 12 03:36:01 CEST 2012


On Sun, Aug 12, 2012 at 11:17 AM, Victor Stinner
<victor.stinner at gmail.com> wrote:
> The idea would be to allow the developer to specify explicitly what he
> wants to optimize. I'm using a configuration class with a list of what
> can be optimized (ex: len(int)), but it can be changed to something
> different later.
>
> It must be configurable to be able to specify: "this specific variable
> is constant in my project"..

That sounds like a plan. It's possibly even worth making blanket
statements like "in this module, once a name is bound to an object, it
will never be rebound to an object of different type".

ChrisA


More information about the Python-Dev mailing list