Compilation failed; see the compiler error output for details.

1. As运行时报错:

Compilation failed; see the compiler error output for details.

编译失败;有关详细信息,请参见编译器错误输出。

2. 解决方案

在terminal中输入gradlew compileDebugSources 可以看到具体原因以及报错行号

> Task :app:compileDebugJavaWithJavac FAILED
ANTLR Tool version 4.5.3 used for code generation does not match the current runtime version 4.7.1ANTLR Runtime version 4.5.3 used for parser compilation does not match the current runtime version 4.
7.1ANTLR Tool version 4.5.3 used for code generation does not match the current runtime version 4.7.1ANTLR Runtime version 4.5.3 used for parser compilation does not match the current runtime version
 4.7.1F:\Android\app\src\main\java\com\db\dao\ChatRowDao.java:22: 错误: Not sure how to handle insert method's return type.
    Long insert(ChatRow... chatRows);
         ^
1 个错误

FAILURE: Build failed with an exception.

你可能感兴趣的:(Compilation failed; see the compiler error output for details.)