Added a new convenience property on lldb.SBThread names "frames" which always returns a complete list of all lldb.SBFrame objects:
(lldb) script
>>> frames = lldb.thread.frames
>>> for frame in frames:
... print frame
Also changed all of the "__repr__" methods to strip any trailing newline characters so we don't end up with entra newlines.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@149466 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/scripts/Python/interface/SBThread.i b/scripts/Python/interface/SBThread.i
index c77706a..fbb1e4e 100644
--- a/scripts/Python/interface/SBThread.i
+++ b/scripts/Python/interface/SBThread.i
@@ -175,6 +175,13 @@
GetDescription (lldb::SBStream &description) const;
%pythoncode %{
+ def get_thread_frames(self):
+ frames = []
+ for frame in self:
+ frames.append(frame)
+ return frames
+
+
__swig_getmethods__["id"] = GetThreadID
if _newclass: x = property(GetThreadID, None)
@@ -190,6 +197,9 @@
__swig_getmethods__["num_frames"] = GetNumFrames
if _newclass: x = property(GetNumFrames, None)
+ __swig_getmethods__["frames"] = get_thread_frames
+ if _newclass: x = property(get_thread_frames, None)
+
__swig_getmethods__["name"] = GetName
if _newclass: x = property(GetName, None)