Settings

Theme

Monitor variables in functions in C++ with Visual Studio extension

d-0.dev

2 points by donadigo 2 years ago · 1 comment

Reader

donadigoOP 2 years ago

Hello HN, for about 6 months I've been developing a Visual Studio extension that makes it easier to debug & inspect dynamic C++ code that changes state e.g every frame. The newest feature I added to the extension is showing real-time changes alongside each line. This works kind of like a global, immediate watch, but without any breakpoints - this is really useful in game development where you'd like to track variables that change state all the time.

The feature works by setting the cursor inside a function, and the extension will start showing you the code paths that are executed and what local variables are changing in it. You can also use it as a function recorder with no breakpoints - just set the cursor in the function, execute an action that calls the function and you'll be able to trace everything that the function did.

Here's a demo of the feature: https://www.youtube.com/watch?v=5bfUWJYEQCw

Marketplace: https://marketplace.visualstudio.com/items?itemName=donadigo... (note: this is a paid extension).

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection