Step Filters in ReSharper C++

It hasn’t been long since the first debugging-assistance features — inline values, searchable DataTips, and breakpoints navigation — appeared in ReSharper, but today we’re happy to present yet another cool feature — step filters in C++.

Why do you need step filters? Well, the illustration below explains pretty much everything:

ReSharper step filters

Some functions never need to be stepped into because they are either very simple or very well tested. But the problem is that the debugger cannot tell which functions are worth debugging and which aren’t, and therefore Step Into will not miss any user function on its way.
Visual Studio’s Just My Code functionality takes basic care of this problem by ignoring non-user code and letting you customize ignored symbols using text config files.

However with ReSharper C++, you can now visually maintain step filters — a list of function masks that tells the debugger what should be skipped on stepping. By default, this list includes a lot of library functions and it can be extended.

Of course, ReSharper wouldn’t be ReSharper without having some handy goodies here: to quickly add a function to the filters, you can press Alt+Enter on that function while debugging and pick the corresponding action:

A context action that adds a ReSharper step filter

The filters are stored using ReSharper’s layered settings. By default, the action saves the filter in the ‘Solution personal’ layer, but you can use the action’s submenu to choose where the filter should be saved — e.g in the ‘Solution team-shared’ layer, so that this filter will be also available to your teammates.

You can study and further configure step filters on the Tools | Debugging | C++ options page:

ReSharper C++: step filter options

As always, your feedback regarding this feature is most welcome, and you can try it right now in the latest build of ReSharper 2018.1 EAP.

This entry was posted in ReSharper C++ Tips & Tricks and tagged , , . Bookmark the permalink.

3 Responses to Step Filters in ReSharper C++

  1. HamRusTal says:

    Sorry for the following offtopic:
    The page says that in EAP6, “ReSharper C++ introduces the Includes Profiler tool window”. I installed that and looked everywhere but failed to find the tool. How do I access it? (JIC, I only installed R# C++, without the greater R#).

    • Dmitry Matveev says:

      In EAP6, you can select a C++ project or a solution with a C++ project in the Solution Explorer, or just some source files in a C++ project, right-click, and pick the ‘Includes Profiler’ action in the context menu.
      In 2018.1 release we are also going to add new actions to the main menu (‘ReSharper | Inspect | Analyze Includes in Solution’ and ‘ReSharper | Inspect | Analyze Includes in Current Project’)

  2. Pingback: ReSharper Ultimate 2018.1 リリース! | JetBrains ブログ

Leave a Reply

Your email address will not be published. Required fields are marked *