[Lldb-commits] [PATCH] D112167: [lldb/Plugins] Refactor ScriptedThread register context creation
Med Ismail Bennani via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed Nov 10 11:54:22 PST 2021
mib requested review of this revision.
mib marked 2 inline comments as done.
mib added inline comments.
================
Comment at: lldb/source/Plugins/Process/scripted/ScriptedThread.cpp:105
+ lldb::RegisterContextSP reg_ctx_sp;
+ Status error;
+
----------------
JDevlieghere wrote:
> It looks like this error is set but never used/returned? Should this return an `Expected<RegisterContextSP>` with the caller dealing with the error?
This follows the `Thread::CreateRegisterContextForFrame` base definition, returning a `RegisterContextSP` and not taking a `Status&` as an argument. I agree this should be refactored but that should be done on a separate patch.
For now, I refactored the code to log the error on the thread channel.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112167/new/
https://reviews.llvm.org/D112167
More information about the lldb-commits
mailing list