[Lldb-commits] [lldb] [LLDB] Add formatters for MSVC STL std::shared_ptr (PR #147575)

Michael Buch via lldb-commits lldb-commits at lists.llvm.org
Wed Jul 9 06:56:13 PDT 2025


================
@@ -16,7 +16,7 @@ lldb::ValueObjectSP lldb_private::formatters::GetDesugaredSmartPointerValue(
 
   auto arg = container_type.GetTypeTemplateArgument(0);
   if (!arg)
-    return nullptr;
+    return ptr.GetSP(); // FIXME: PDB doesn't have info about template arguments
----------------
Michael137 wrote:

Ah but this only is a problem with PDB. So for MSVC STL+DWARF this would pass (which I guess is what the bots are running?).

I don't think we need the FIXME in that case tbh. I think it's reasonable to say that if we don't have enough debug-info to look at the template argument, then let the pointer type be whatever we got from debug-info.

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


More information about the lldb-commits mailing list