Refine double-click navigation while debugging - #1139
Conversation
…ction OnTokenDoubleClicked opened every address-literal token (integer, possible address, code-relative) in a separate pane while debugging. When the target falls inside the function the user is already viewing, they most likely want to jump to it in place, so fall through to the default in-pane navigation in that case and only open a second pane for out-of-function targets. Closes #1136 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
OnTokenDoubleClicked ignored data symbol tokens (e.g. data_100003fa9) and inline string tokens, so they fell through to the default in-pane navigation. While a debug session is live, resolve the referenced address and open it in another pane instead, so the disassembly the user is looking at stays put. Closes #1137 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Just wish to mention -- I somehow think that this should actually become the default behavior when the user is not debugging, or at least an option that can be enabled |
fuzyll
left a comment
There was a problem hiding this comment.
Only saw one thing I think we should change. I did not have a chance to test my theory about where this would show up because I did not build this myself, though, so I might be wrong.
| target = token.addr; | ||
| haveTarget = true; | ||
| } | ||
| else if (token.type == DataSymbolToken || token.type == StringToken) |
There was a problem hiding this comment.
I am reasonably certain this is too broad? In some other places where we deal with StringTokens, we also check the token.context to see what kind of token it is. A StringToken that's StringDisplayTokenContext is, I believe, not really intended to be navigable in this way. For example, I think if you double-clicked on a calling convention string, you would wind up navigating to...I genuinely do not know where, with this code.
Two fixes to
OnTokenDoubleClicked:data_100003fa9) and inline string tokens now open in another pane while debugging, instead of falling through to default in-pane navigation.Closes #1136
Closes #1137
🤖 Generated with Claude Code