解决方法如下:
1、使用Ant编译时,未打开debug开关,在写javac
任务时确认debug=true,否则不能调试。THe settings for the eclipse
compiler don't affect the ant build and even if you launch the ant
build from within eclipse. ant controls it's own compiler
settings.you can tell ant to generate debugging info like this
'javac ...
debug="true".../>;
2、编译器的设置问
题,window->preferences->java->Compiler在compiler起始页,classfile
Generation区域中确认已经勾选了All line number attributes to generated class
files。如果已经勾选,从新再Apply一下。从项目层次进行设定,项目属性->java
compiler同样在起始页,确定已经勾选。
最简单的方法就是:删掉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可以执行完全或者进入下一个断点中。
Photoshop|
Dreamweaver|
SVG|
WebGL|
Visual Studio|
PowerDesigner|
Eclipse|
Git|
Apache Ant|
Atom|
Composer|
CodeSmith|
Flex|
Gradle|
Maven|
Sublime Text3|
SVN|
Tableau|
Vim|
Chrome开发者工具|
OpenGL|
Unity|
Direct3D|
用户登录
还没有账号?立即注册
用户注册
投稿取消
文章分类: |
|
还能输入300字
上传中....