This is the mail archive of the
archer@sourceware.org
mailing list for the Archer project.
Error in FrameIterator.py
- From: Teng Lin <teng dot lin at gmail dot com>
- To: archer at sourceware dot org
- Date: Sat, 11 Apr 2009 11:12:18 -0400
- Subject: Error in FrameIterator.py
Hi All,
I run into a problem when exploring new-backtrace command.
(gdb) source -p /opt/archer/share/gdb/python/gdb/command/backtrace.py
(gdb) new-backtrace
Traceback (most recent call last):
File "/opt/archer/share/gdb/python/gdb/command/backtrace.py", line
193, in invoke
for pair in iter:
File "/opt/archer/share/gdb/python/gdb/FrameIterator.py", line 30,
in next
if result == None:
TypeError: Frame object expected in comparison.
Error occurred in Python command: Frame object expected in comparison.
Simply changing "if result == None:" to "if result is None:" can fix
the problem.
Apparently, the error message is thrown by frapy_richcompare function
in python-frame.c. Shouldn't frapy_richcompare return Py_RETURN_FALSE.
I have a few other questions for Tom and other Archer developers.
An empty dictionary is always return when fields method from of a type
is called. Do we actually implement it?
I have preliminary success of translating part of Misc/gdbinit to
python. One thing I would like to achieve is to print the value of
certain built-in type, like int, float, string, list, dict and tuple.
Tom, I recall you have a long term to support debugging python or
other dynamic language natively in gdb, can you elaborate the idea a
bit?
Best regards,
Teng