wallace added inline comments.
================ Comment at: lldb/source/Plugins/Trace/intel-pt/IntelPTDecoder.cpp:227 + +static Expected<DecodedThreadSP> DecodeLiveThread(const ThreadSP &thread_sp, + TraceIntelPT &trace) { ---------------- don't use expected. The DecodedThread object already can store errors. Just return a DecodedThreadSP and assign it a single error and return it. If you need to return the failed DecodedThread before you know the size of the buffer, just pass 0 as size ================ Comment at: lldb/source/Plugins/Trace/intel-pt/IntelPTDecoder.cpp:241 +DecodedThreadSP LiveThreadDecoder::DoDecode() { + return *(DecodeLiveThread(m_thread_sp, m_trace)); } ---------------- remove the *, because we will make DecodeLiveThread not return an Expected Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122293/new/ https://reviews.llvm.org/D122293 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits