================ @@ -218,10 +218,11 @@ bool ScriptedSyntheticChildren::FrontEnd::MightHaveChildren() { return m_interpreter->MightHaveChildrenSynthProviderInstance(m_wrapper_sp); } -size_t ScriptedSyntheticChildren::FrontEnd::GetIndexOfChildWithName( - ConstString name) { +llvm::Expected<size_t> +ScriptedSyntheticChildren::FrontEnd::GetIndexOfChildWithName(ConstString name) { if (!m_wrapper_sp || m_interpreter == nullptr) - return UINT32_MAX; + return llvm::createStringError("Cannot find index of child '%s'", + name.AsCString()); ---------------- Michael137 wrote:
Should we be more descriptive with where the error came from? E.g., "ScriptedSyntheticChildren::FrontEnd cannot find index of child '%s'"? Same with the other places in this PR https://github.com/llvm/llvm-project/pull/136693 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits