[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:31 PDT 2024


================
@@ -38,13 +42,21 @@ ScriptedStackFrameRecognizer::RecognizeFrame(lldb::StackFrameSP frame) {
   ValueObjectListSP args =
       m_interpreter->GetRecognizedArguments(m_python_object_sp, frame);
   auto args_synthesized = ValueObjectListSP(new ValueObjectList());
-  for (const auto &o : args->GetObjects()) {
-    args_synthesized->Append(ValueObjectRecognizerSynthesizedValue::Create(
-        *o, eValueTypeVariableArgument));
-  }
+  if (args)
+    for (const auto &o : args->GetObjects())
+      args_synthesized->Append(ValueObjectRecognizerSynthesizedValue::Create(
+          *o, eValueTypeVariableArgument));
----------------
JDevlieghere wrote:

```suggestion
  if (args) {
    for (const auto &o : args->GetObjects())
      args_synthesized->Append(ValueObjectRecognizerSynthesizedValue::Create(
          *o, eValueTypeVariableArgument));
}
```

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


More information about the lldb-commits mailing list