[Lldb-commits] [lldb] [lldb] Upgrade `GetIndexOfChildWithName` to use `llvm::Expected` (PR #136693)

Michael Buch via lldb-commits lldb-commits at lists.llvm.org
Wed Apr 23 14:28:18 PDT 2025


================
@@ -395,8 +395,8 @@ lldb_private::formatters::NSSetISyntheticFrontEnd::GetIndexOfChildWithName(
       (idx < UINT32_MAX && idx >= CalculateNumChildrenIgnoringErrors()))
     return llvm::createStringError(
         "'SyntheticChildrenFrontEnd::NSSetISyntheticFrontEnd' cannot find "
-        "index of child '%s'",
-        name.AsCString());
+        "index of child '%s'. (idx='%d')",
----------------
Michael137 wrote:

```suggestion
        "index of child '%s'. (idx='%" PRu32 "')",
```
(same goes for the other `idx` logs)

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


More information about the lldb-commits mailing list