[Lldb-commits] [PATCH] D43886: [lldb] Add GetCurrentException and GetCurrentExceptionBacktrace APIs to SBThread
Kuba (Brecka) Mracek via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Sun Nov 11 17:21:31 PST 2018
kubamracek added a comment.
Hi, I've updated this patch after a while. Since then, StackFrameRecognizers have already landed, so this patch now just adds one subclass of a StackFrameRecognizer.
> It seems however like providing some interesting ValueObjects is a pretty common thing to do, so maybe it would be better to have an API like:
> `ValueObjectSP GetValueObjectOfKind(const char *kind);`
For now, I've kept the new method, `GetExceptionObject()`. If you'd still like me to change it into a string-based API, let me know, I'll be happy to change it. I agree that it doesn't make sense to keep adding methods to the base RecognizedStackFrame class.
> Maybe it would be better to change --extended to take an enum, and then do:
> `thread backtrace --extended exception`
I can add that. On top of the backtrace, the exception has a class name and message (at least in Obj-C), which is also important to present via some command. Do you want to keep `thread exception` as well? Or make `thread backtrace -e exception` be the only way to access the class+message of an exception?
More information about the lldb-commits