JDK compilance is set wrong when I "Refresh Gradle Project"


(Annony Mus) #1

In my Gradle project, I set the targetCompatibility and sourceCompatibility to 11 in build.gradle. After “Refresh Gradle Project”, Buldship correctly detect the targetCompatibility and add correct JRE System Library to the classpath. However, it also modifies the project settings. When I open the Project Properties window after refreshing, in “Java Compiler”, I found the "Use compliance from execution environment… " option disabled, and the Compiler compliance level set to 1.8. This only happens when I set the target&sourceCompatibility to 11. If I set them to 10, project settings are all set correctly.
Is it a bug? I hope future Buildship release would automatically change the JDK Compliance object so that "Use compliance from execution environment… " is enabled.