Do not add JDK .jar roots if the JDK is modular (9+)
Files like ant-javafx.jar, deploy.jar, java.jnlp.jar, javafx-swt.jar etc should not be added to the classpath if JDK home points to a JDK 9 distribution
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
compiler/testData/javaModules/jdkModulesFromNamed/main/test.kt:11:24: error: unresolved reference: httpserver
|
||||
val s: com.sun.net.httpserver.HttpServer? = null
|
||||
^
|
||||
compiler/testData/javaModules/jdkModulesFromNamed/main/test.kt:19:20: error: unresolved reference: javafx
|
||||
val x: com.sun.javafx.tools.ant.AntLog? = null
|
||||
^
|
||||
COMPILATION_ERROR
|
||||
|
||||
@@ -14,4 +14,8 @@ fun main(args: Array<String>) {
|
||||
// Module oracle.desktop
|
||||
val a: com.oracle.awt.AWTUtils? = null
|
||||
println(a)
|
||||
|
||||
// No module, this class is declared in $JDK_9/lib/ant-javafx.jar
|
||||
val x: com.sun.javafx.tools.ant.AntLog? = null
|
||||
println(x)
|
||||
}
|
||||
|
||||
@@ -1 +1,4 @@
|
||||
OK
|
||||
compiler/testData/javaModules/jdkModulesFromUnnamed/main/test.kt:19:33: error: unresolved reference: ant
|
||||
val x: com.sun.javafx.tools.ant.AntLog? = null
|
||||
^
|
||||
COMPILATION_ERROR
|
||||
|
||||
@@ -14,4 +14,8 @@ fun main(args: Array<String>) {
|
||||
// Module oracle.desktop
|
||||
val a: com.oracle.awt.AWTUtils? = null
|
||||
println(a)
|
||||
|
||||
// No module, this class is declared in $JDK_9/lib/ant-javafx.jar
|
||||
val x: com.sun.javafx.tools.ant.AntLog? = null
|
||||
println(x)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user