Tag: 调试

没有提供足够的数据给HAL,预期的位置

我在Android Studio中遇到了这个错误。 我只是想按下按钮时打印文本。 我得到下面的错误,每当我按下按钮时出现。 如果我取消注释意图,它也可以很好地工作,但更多的代码我有更多的错误更改。 我不确定这是真正的错误。 我这样说是因为我有一个完整的应用程序(不是这个),它使用翻新和github API来搜索回购。 这个按钮是搜索的纽带。 如果我拼写一个单词的应用程序完美的作品。 我终于到了这个简化的应用程序,试图find根本原因。 请帮忙。 1。 10-17 15:33:56.569 1404-1431/? W/audio_hw_generic: Not supplying enough data to HAL, expected position 2045606 , only wrote 1793520 这是代码 import android.content.Intent import android.support.v7.app.AppCompatActivity import android.os.Bundle import android.widget.Button import android.widget.EditText class MainActivity : AppCompatActivity() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) val editText […]

使用JUnit运行时,Intellij IDEA不会停止在Kotlin断点处

当试图执行一些Kotlin代码,同时也使用JUnit时,Intellij IDEA将执行代码直到结束,而不是停在断点处。 演示: class Tester { @Test fun shouldBreakpoint() { //Line where threads should suspend: println(“Should Suspend Here”) //Breakpoint added to this line println(“Shouldn’t run this code unless I release above breakpoint”) } } 当点击“Debug Tester”或“Debug shouldBreakpoint”时,不会有断点。 控制台输出两个打印行,没有停在断点处。 如果使用Java编写相同的代码,则调试器将工作: public class Testerino { @Test public void shouldBreakpoint() { System.out.println(“Should Suspend Here”); //Breakpoint added to this […]