On Fri, Sep 16, 2011 at 8:44 AM, Albert Zeyer <albzey at googlemail.com> wrote: > Hi list, > > I thought it would be nice in Python to allow some sort of meta coding > (which goes far ahead of simple function descriptors). > > The most straight forward way would be to allow operations on the AST. 1. This kind of suggestion is more appropriately directed to python-ideas 2. We already support this, look at the ast module and in particular the ast.PyCF_ONLY_AST flag to the compile() builtin function. For an example of advanced usage, look at the py.test module and it's meta-importer that rewrites assert statements Regards, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
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