With C++ files, why does the right-click option to 'Find All References' of a variable usage return all spelling usages in the entire project whether related or not. How can this Find operation be limited to just the actual variable concerned?
As for MSVC 2015 Update 2 it does actually find all the references to a variable, including comments and strings.
When you get a list of references you can see different icons for each element denoting different types of references: like comments, strings or variables with the same name. Then you have two options when walking though the list: visit all found locations (F4, Shift+F4) or only confirmed references using the black arrow buttons, as shown here:
I would also recommend to rescan solution if searching doesn't work correctly (Solution Explorer > right click > Rescan Solution).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With