[Lldb-commits] [lldb] [lldb] Extend frame recognizers to hide frames from backtraces (PR #104523)

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Tue Aug 20 11:40:32 PDT 2024


================
@@ -1202,6 +1202,19 @@ bool SBFrame::IsArtificial() const {
   return false;
 }
 
+bool SBFrame::IsHidden() const {
+  LLDB_INSTRUMENT_VA(this);
+
+  std::unique_lock<std::recursive_mutex> lock;
+  ExecutionContext exe_ctx(m_opaque_sp.get(), lock);
+
+  StackFrame *frame = exe_ctx.GetFramePtr();
+  if (frame)
+    return frame->IsHidden();
----------------
JDevlieghere wrote:

```suggestion
  if (StackFrame *frame = exe_ctx.GetFramePtr())
    return frame->IsHidden();
```

https://github.com/llvm/llvm-project/pull/104523


More information about the lldb-commits mailing list