https://github.com/kastiglione updated 
https://github.com/llvm/llvm-project/pull/131233

>From 47bd3d18947f9d34472095f6064f00016c20bc4b Mon Sep 17 00:00:00 2001
From: Dave Lee <davelee....@gmail.com>
Date: Thu, 13 Mar 2025 15:43:48 -0700
Subject: [PATCH 1/2] [lldb] Remove use of comma operator (NFC)

---
 lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp 
b/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
index d49c27f0006bc..5a904f78a86de 100644
--- a/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
+++ b/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
@@ -362,7 +362,8 @@ lldb::ValueObjectSP 
ValueObjectSynthetic::GetNonSyntheticValue() {
 }
 
 void ValueObjectSynthetic::CopyValueData(ValueObject *source) {
-  m_value = (source->UpdateValueIfNeeded(), source->GetValue());
+  source->UpdateValueIfNeeded();
+  m_value = source->GetValue();
   ExecutionContext exe_ctx(GetExecutionContextRef());
   m_error = m_value.GetValueAsData(&exe_ctx, m_data, GetModule().get());
 }

>From f506bff7d69f1aeca1547cb7c76b132090650b3e Mon Sep 17 00:00:00 2001
From: Dave Lee <davelee....@gmail.com>
Date: Sat, 15 Mar 2025 10:52:34 -0700
Subject: [PATCH 2/2] Require source be in success state before copying

---
 lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp 
b/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
index 5a904f78a86de..ae2b9bebbb12d 100644
--- a/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
+++ b/lldb/source/ValueObject/ValueObjectSyntheticFilter.cpp
@@ -362,7 +362,8 @@ lldb::ValueObjectSP 
ValueObjectSynthetic::GetNonSyntheticValue() {
 }
 
 void ValueObjectSynthetic::CopyValueData(ValueObject *source) {
-  source->UpdateValueIfNeeded();
+  if (!source->UpdateValueIfNeeded())
+    return;
   m_value = source->GetValue();
   ExecutionContext exe_ctx(GetExecutionContextRef());
   m_error = m_value.GetValueAsData(&exe_ctx, m_data, GetModule().get());

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to