[Lldb-commits] [lldb] [lldb] Upgrade `GetIndexOfChildWithName` to use `llvm::Expected` (PR #136693)
Adrian Prantl via lldb-commits
lldb-commits at lists.llvm.org
Thu Apr 24 12:56:43 PDT 2025
================
@@ -67,7 +67,9 @@ TypeFilterImpl::FrontEnd::GetIndexOfChildWithName(ConstString name) {
}
}
}
- return UINT32_MAX;
+ return llvm::createStringError(
+ "'SyntheticChildrenFrontEnd::FrontEnd' cannot find index of child '%s'",
----------------
adrian-prantl wrote:
> Adding logging to all these places feels a bit noisy.
Currently the error is dropped silently. You wouldn't replace that with adding logging everywhere. My suggestion would be to:
- return errors that are understandable to users
- where necessary add logging in the error case with additional information
https://github.com/llvm/llvm-project/pull/136693
More information about the lldb-commits
mailing list