[Compiler-sig] sharing AST between C and Python

Jeremy Hylton jeremy@zope.com
Mon, 22 Apr 2002 00:35:46 -0400


Has anyone given thought about how to share an AST between the Python
core and user code written in Python?  I think I mentioned earlier
that I was leaning towards an explicit "pickling" phases to copy an
AST across the boundary rather than trying to share references to a
single struct.  Does anyone else have an opinion?

I'm asking because the first draft of astmodule.c is winding down, and
I'll need the pickler soon if I want to do any noodling with the
converted AST.

Jeremy

PS That's pickling in the ASDL sense, which is similar to but not the
same as pickling in the Python sense.