This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: pretty printing with python
- From: Tom Tromey <tromey at redhat dot com>
- To: "Klaus Rudolph" <lts-rudolph at gmx dot de>
- Cc: gdb at sourceware dot org
- Date: Mon, 02 May 2011 08:31:59 -0600
- Subject: Re: pretty printing with python
- References: <20110502135532.164670@gmx.net>
>>>>> "Klaus" == Klaus Rudolph <lts-rudolph@gmx.de> writes:
Klaus> I want to start with writing a pretty printer for gdb, but can't
Klaus> find a startup for my own printer.
Klaus> First: All example contains a line
Klaus> import gdb.printing
Klaus> But this results in
Klaus> Traceback (most recent call last):
Klaus> File "/home/krud/projekte/myppc8000/ppc_8000_938/test.py", line 3, in <module>
Klaus> import gdb.printing
Klaus> ImportError: No module named printing
This means your GDB is too old. `gdb.printing' is not in any release
yet; it will make its debut in 7.3.
You can write printers so that they work with both the new- and
old-styles here. The libstdc++ printers do this.
Tom