Search code examples
eclipsevisual-studiodebuggingbreakpoints

Breakpoints grouping and naming in eclipse and Visual Studio


I work with large project having different modules, subprojects. When I am working with one module I need to create set of debugpoints/breakpoints to debug that module.

When I have to work with other one, to debug it, I have to create another set of breakpoints and disable the ones created to debug the earlier module.

When I want to debug (dont conclude that I write buggy code...its just that....it just happens :p) third module, I have to create thrid set of debug points, disable the earlier two sets corresponding to earlier two modules.

Same with debugging fourth module.

Same with debugging fifth module.

Now I want to come back to debugging first module. I have breakpoints related to all modules in my breakpoint window. Say 5 breakpoints corresponding to each module. Total 5*5 = 25. Now I have to go through reading each breakpoint checking which belongs to the first one, enabling them and disabling others.

Am I missing something. Is some simpler/standard way to ease this already there in eclipse.

  • I feel there should be say "Save set of breakpoints" option which note all the breakpoints currently in the breakpoint window as belonging to same set and will then ask us to give name to that set, say in my case "Module 1".

  • Then another option "Create new breakpoint set", which will clear up breakpoint window without deleting already created named breakpoint sets

  • Then, ofcourse the option to "Load breakpoint set" which will simply show up the set we saved as, say in dropdownlist. We select the named breakpoint set and it will end up loading those set of breakpoints.

Q. Am I overthinking? Is similar stuff already there? Also willing to know if similar stuff is there in Visual Studio too


Solution

  • Use 'Breakpoint Working Sets' for this.

    In the Breakpoints view (in the Debug perspective) click the small triangle at the top right of the view and select the 'Working Sets...' menu item. This will let you manage the breakpoint working sets.

    More details in the Eclipse help