Scala+Android: Is anybody successfully building and debugging in Eclipse?

前端 未结 2 1811
北恋
北恋 2021-02-14 01:16

So far, the only way I\'ve been able to debug within Eclipse is to use Treeshaker with Scala IDE\'s buggy 2.8 branch. If I try to build with Scala IDE without Treeshaker, I get

相关标签:
2条回答
  • Using AndroidProguardScala, I am successful in debugging, using scala 2.10 and Eclipse 3.7 It also deals with for comprehensions as the usual plugin. See the detailed answer there:

    Eclipse, Android, Scala made easy but still does not work

    The only missing feature is the new scala debugger in the latest scala eclipse plugin, which is not yet integrated. So for example, to debug a map, you will have to go though files such as Map.scala, ArrayBuffer.scala, Object.scala, and so on.

    0 讨论(0)
  • 2021-02-14 01:44

    In general debugging Scala code running on Android using Eclipse works well and behaves more or less like debugging Scala on regular (non-Android) applications.

    I use sbt with sbt-android and android:start-emulator or android:start-device.

    Depending on whether I need to debug the application startup, I set the option to wait for the debugger in the developer settings on the device or emulator. To do this, run "DevTools" / "Development Settings". Select your application and check "Wait for Debugger".

    Then you have to select the process to debug in DDMS. Make sure the debug port is shown, and then connect with the Eclipse debugger.

    A potential cause for the debugger not installing the breakpoints is that the source code line has no direct equivalent in byte code. For comprehensions come to mind.

    0 讨论(0)
提交回复
热议问题