================
@@ -181,29 +226,68 @@ const char *Status::AsCString(const char
*default_error_str) const {
// Clear the error and any cached error string that it might contain.
void Status::Clear() {
- m_code = 0;
- m_type = eErrorTypeInvalid;
- m_string.clear();
+ if (m_error)
+ LLDB_LOG_ERRORV(GetLog(LLDBLog::API), std::move(m_error),
+ "dropping error {0}");
+ m_error = llvm::Error::success();
+ llvm::consumeError(std::move(m_error));
----------------
adrian-prantl wrote:
I moved the consume to operator=.
https://github.com/llvm/llvm-project/pull/106774
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits