Replies: 1 comment 1 reply
-
This relates a bit to microsoft/debug-adapter-protocol#458 There's currently nothing in the specification that would allow nvim-dap to surface this in a way that works across debug adapters. My workaround so far is to just select the whole expression and then use the hover widget on it |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi! I'm a heavy user of nvim-dap and nvim-dap-ui, with codelldb for debugging Rust. Rust makes heavy use of implicit return values, like this super contrived example:
My experience with nvim-dap is that it's not possible to put a breakpoint on line 2 and inspect the value. To get around that, I frequently bind the value to a variable, which I can then inspect with the debugger.
The problem is that this leads to a lot of non-idiomatic Rust, and clippy (Rust's linter) doesn't like it. It's also harder to take this approach when debugging third party code.
Codelldb and gdb both have
finish
, which runs the current stack frame to completion, and prints the return value.Perfect! The only hangup is that I haven't found a way to surface that return value in nvim-dap. Is this a feature that others would find useful? Is there already a way to do it that I missed? Thanks for the discussion.
Beta Was this translation helpful? Give feedback.
All reactions