[Lldb-commits] [lldb] [lldb] Add SetValueFromCString API to	SyntheticFronend (PR #67309)
    Alex Langford via lldb-commits 
    lldb-commits at lists.llvm.org
       
    Mon Sep 25 13:49:15 PDT 2023
    
    
  
================
@@ -34,7 +34,9 @@ class SyntheticChildrenFrontEnd {
 
 public:
   SyntheticChildrenFrontEnd(ValueObject &backend)
-      : m_backend(backend), m_valid(true) {}
+      : m_backend(backend), m_valid(true) {
+    backend.SetSyntheticFrontend(this);
+  }
----------------
bulbazord wrote:
Ignoring whether or not ValueObject should hold a pointer to a SyntheticFrontEnd, I'm concerned about the lifetime management of this solution. If a SyntheticChildrenFrontEnd is destroyed, the underlying `ValueObject` will be holding a dangling pointer.
https://github.com/llvm/llvm-project/pull/67309
    
    
More information about the lldb-commits
mailing list