在我将gradle版本从3.2.0更新到3.2.1之后 我所有的lambda表达式都坏了:
错误:找不到符号方法元工厂(查找,字符串,MethodType,MethodType,MethodHandle,MethodType)
我的模块级build.gradle看起来像这样:
apply plugin: 'com.android.application'
android {
compileSdkVersion 28
defaultConfig {
applicationId "xyz.test.lambdatest"
minSdkVersion 16
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility = '1.8'
targetCompatibility = '1.8'
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
}
应用程序级build.gradle:
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.2.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
google()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
谁能告诉我为什么它与gradle 3.2.0一起使用而不与gradle 3.2.1一起使用?