================
@@ -287,8 +291,52 @@ bool
lldb_private::formatters::LibStdcppStringSummaryProvider(
} else
return true;
} break;
- case eAddressTypeHost:
- break;
+ case eAddressTypeHost: {
+
+ DataExtractor data;
+ Status error;
+ valobj.GetData(data, error);
+ if (error.Fail())
+ return false;
+
+ lldb::offset_t offset = 0;
+ AddressType child_addressType = valobj.GetAddressTypeOfChildren();
+ if (child_addressType == eAddressTypeLoad)
+ {
+ // We have the host address of our std::string
+ // But we need to read the pointee data from the debugged process.
+ ProcessSP process_sp(valobj.GetProcessSP());
+ // We want to read the address from std::string, which is the first 8
bytes.
+ lldb::addr_t addr = data.GetAddress(&offset);
+ if (!addr)
+ {
----------------
clayborg wrote:
The `{` goes at the end of the `if` line per llvm coding guidelines
https://github.com/llvm/llvm-project/pull/89110
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits