Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

eclipse can't remove certain breakpoints

Double-clicking in the blue bar on the left of eclipse sets a breakpoint. Double-clicking again removes the breakpoint. This works great for me but if I use git to checkout a different branch, often times the blue dots for breakpoints get "confused" or something. I can no longer double-click to unset them. I am forced to go into debug perspective, and find the breakpoint in the "breakpoints" view and then right click and remove. Does anybody have an easier solution for this? I am coding in java on windows 7 for what it's worth.

I can reproduce this bug with this code (assume the if is line 1):

if(bool)
{
  // comment
  doSomething();
} else {
  doOther();
}

I breakpoint on line 4 - doSomething(). Then I put a new line above the if to shift everything down. (moving the breakpoint on line 5). Then I do git stash save. When I click back to eclipse, the blue dot is displayed on the correct line, but the breakpoint window still says line 5. If I double click to disable, it actually adds a second breakpoint on line 4.

I feel like I should report this to the Eclipse guys.

like image 925
benathon Avatar asked Feb 07 '13 08:02

benathon


People also ask

How do I delete all Debug points?

You can delete all breakpoints in one of the following ways: On the Debug menu, click Delete All Breakpoints. On the toolbar of the Breakpoints window, click the Delete All Breakpoints button.

How do I fix Java exception breakpoint in Eclipse?

You can fix this immediately by opening the Markers view and delete the Java Exception Breakpoints. However, to permanently remove this type of breakpoints, you have to go to the Java Debug options and uncheck the "Suspend excecution on uncaught exceptions" option.

How do you remove a breakpoint in Java?

Directly to the left of the line where you want to remove the breakpoint, open the marker bar pop-up menu and select Toggle Breakpoint. The breakpoint is removed from the workbench. You can also double-click directly on the breakpoint icon to remove it.


Video Answer


1 Answers

open debug perspective [right conrer]

go to breakpoints

click clear all breakpoints [double X] or scroll until you find the breakpoint which doesn't want to go away and delete it.

like image 94
TheWhiteRabbit Avatar answered Oct 18 '22 13:10

TheWhiteRabbit