Using bytecode, not code objects
Raymond Hettinger
python at rcn.com
Mon Feb 6 17:07:04 EST 2006
Fabiano Sidler wrote:
> 2006/1/29, Fabiano Sidler <fabianosidler at gmail.com>:
> > 28 Jan 2006 22:02:45 -0800, Raymond Hettinger <python at rcn.com>:
> > > But if you want to make your life unnecessarily hard, you can hack the
> > > compiler module just upstream from the creation of the code object --
> > > alter the newCodeObject() method in pyassem.py.
> >
> > Thanks! I think this will help me, because it demonstrates how a code
> > object is to be created (with new.code), although in a very
> > complicated way.
>
> Are you familiar with this module? I don't get the essence of it, even
> with pdb (which I'm surely not using as neatly as it could be). Or is
> there any documentation on it I couldn't find?
The pysassem module is part of the compiler package:
http://docs.python.org/lib/compiler.html
Raymond
More information about the Python-list
mailing list