[Lldb-commits] [PATCH] D147831: [lldb-vscode] Implement RestartRequest
Jorge Gorbe Moya via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Mon Apr 10 18:46:56 PDT 2023
jgorbe marked 2 inline comments as done.
jgorbe added inline comments.
================
Comment at: lldb/tools/lldb-vscode/VSCode.h:146
+ // arguments if we get a RestartRequest.
+ llvm::json::Object last_launch_or_attach_request;
lldb::tid_t focus_tid;
----------------
rupprecht wrote:
> std::optional<llvm::json::Object>? And then we can raise an error if the client calls restart and this is std::nullopt.
Done, thanks!
================
Comment at: lldb/tools/lldb-vscode/lldb-vscode.cpp:602
// }
void request_attach(const llvm::json::Object &request) {
g_vsc.is_attach = true;
----------------
rupprecht wrote:
> Should we also set `last_launch_or_attach_request` here?
>
> If the user runs:
> 1) Launch
> 2) Attach
> 3) Restart
>
> I would expect that should fail because of the reasons restarting an attach will fail. But if we don't set `last_launch_or_attach_request`, it will pass, because we set it in (1).
Yup, I missed that one, thanks for catching it! :)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D147831/new/
https://reviews.llvm.org/D147831
More information about the lldb-commits
mailing list