无法在Android Studio中设置断点

来源:互联网 发布:mac管理员名称和密码 编辑:程序博客网 时间:2024/05/02 05:07

有时候在android studio中设置了断点,但是当链接设备后,看到的却是一个带x的断点,

此时链接上手机,也是没法停在断点的,真是急人啊!!!


根据断点失败的提示:

Warning: No executable code found at line 482 in class com.xx.xx.

开始搜索。


StackOverflow上有一篇解释,Cannot set Java breakpoint in Intellij IDEA

  1. If you are using Maven dependencies, go to Maven Projects -> refresh  
  2. If that does not work, Try top menu --> Build --> Rebuild Project  
  3. If that still doesn't work, try top menu --> File --> Invalidate Cache/Restart 
  4. If that still doesn't work, then $CATALINA_BASE/bin/catalina.sh stop, then start 
2和3两个步骤可以解决问题,其他两个应该Maven和Tomcat的,可以忽略

1 0
原创粉丝点击