-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Java 9+: staging classpath handling #9500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
Comments
If all that's missing are the jars from the system classloader, we should be able to get them using |
Closed
nicolasstucki
added a commit
to dotty-staging/dotty
that referenced
this issue
Aug 6, 2020
nicolasstucki
added a commit
to dotty-staging/dotty
that referenced
this issue
Aug 6, 2020
nicolasstucki
added a commit
to dotty-staging/dotty
that referenced
this issue
Aug 6, 2020
nicolasstucki
added a commit
to dotty-staging/dotty
that referenced
this issue
Aug 6, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When run the test set with JDK 11, we get two errors:
(1) Failure in
project/scripts/bootstrapCmdTests
(2) tests/run-staging/i6992
The errors originate from a change of class loading in Java 9 (due to the module system):
https://stackoverflow.com/questions/46694600/java-9-compatability-issue-with-classloader-getsystemclassloader#comment80337394_46694600
In Java 9, the classloader is no longer a
URLClassLoader
, which breaks the following code:https://github.com/lampepfl/dotty/blob/8eea8d8bba1da247553161e981d6d277eb375a4b/compiler/src/dotty/tools/dotc/util/ClasspathFromClassloader.scala#L10-L42
There exists a hack to achieve similar results in Java 9+
https://stackoverflow.com/questions/46519092/how-to-get-all-jars-loaded-by-a-java-application-in-java9
Related PR: #9181
The text was updated successfully, but these errors were encountered: