当我运行' gradle' compileJava,我遇到了这个错误:
incompatible types: List<Object> cannot be converted to List<? extends Serializable>
我的代码在eclipse中很好,并且在eclipse和同样的JVM 1.8.0_112中构建得很好:
List<Object> resultList = new ArrayList<Object>();
List<? extends Serializable> searchResults ;
searchResults = (List<? extends Serializable>) resultList;
Gradle 4.1 with JVM 1.8.0_112(Oracle Corporation 25.112-b15)
使用sourceCompatibility = '1.8'