解决方法如下:1、使用Ant编译时,未打开debug开关,在写javac任务时确认debug=true,否则不能调试。THe settings for the eclipsecompiler don't affect the ant build and even if you launch the antbuild from within eclipse. ant controls it's own compilersettings.you can tell ant to generate debugging info like this'javac ...debug="true".../>;2、编译器的设置问题,window->preferences->java->Compiler在compiler起始页,classfileGeneration区域中确认已经勾选了All line number attributes to generated classfiles。如果已经勾选,从新再Apply一下。从项目层次进行设定,项目属性->javacompiler同样在起始页,确定已经勾选。
最简单的方法就是:删掉workspace下的.metadata,重新导入项目。或者:打开 workspace\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.debug.ui.prefs,里面有一句:org.eclipse.debug.ui.switch_perspective_on_suspend=never改成:org.eclipse.debug.ui.switch_perspective_on_suspend=false然后重启eclipse,调试时会让你重新选择。
那就单步返回即可,也就是说按F6;
F5可以进入某个方法中,F6可以跳过该方法,F8可以执行完全或者进入下一个断点中。
最简单的方法就是:删掉workspace下的.metadata,重新导入项目。或者:打开 workspace\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.debug.ui.prefs,里面有一句:org.eclipse.debug.ui.switch_perspective_on_suspend=never改成:org.eclipse.debug.ui.switch_perspective_on_suspend=false然后重启eclipse,调试时会让你重新选择。
那就单步返回即可,也就是说按F6;
F5可以进入某个方法中,F6可以跳过该方法,F8可以执行完全或者进入下一个断点中。
- 0
- 0
- 0
- 0
- 0
更多推荐
eclipse打断点
发布评论