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/2005-May/054001.html below:

[Python-Dev] AST manipulation and source code generation

[Python-Dev] AST manipulation and source code generation [Python-Dev] AST manipulation and source code generationSylvain Thénault Sylvain.Thenault at logilab.fr
Thu May 26 09:58:10 CEST 2005
> > On 5/24/05, Ka-Ping Yee <python-dev at zesty.ca> wrote:
> >
> >
> >> Would there be any interest in extending the compiler package with  
> >> tools
> >> for AST transformations and for emitting Python source code from  
> >> ASTs?

the astng package from logilab's common library [1] extends compiler AST
nodes with a bunch of methods, including a as_string method on each node
allowing to regenerate a python source code from an ast (other methods
are mainly to ease navigation in the tree or to extract higher level
information from it). Currently it's implemented as a node's method
instead of using a visitor pattern or the like, but that would be easily
done.

[1] http://www.logilab.org/projects/common/

-- 
Sylvain Thénault                               LOGILAB, Paris (France).

http://www.logilab.com   http://www.logilab.fr  http://www.logilab.org

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