Python Pretty printing a struct
Tom Tromey
tromey@redhat.com
Fri Mar 12 20:40:00 GMT 2010
>>>>> "Chris" == Chris Johns <chris@contemporary.net.au> writes:
Chris> (gdb) p the_semaphore->Object.id
Chris> $36 = to_string = {
Chris> id = 436273170,
[...]
Chris> How do I remove the extra "to_string =" ?
Presumably your printer returns it.
Could you post the python code?
Chris> I have also noticed this:
Chris> (gdb) p /x the_semaphore->Object.id
Chris> $37 = 0x1a010012
Chris> Is it expected the actual value is shown in hex rather than the
Chris> numeric fields returned by the pretty print iterator ?
It might be a bug, I am not sure.
Tom
More information about the Gdb
mailing list