forked from scala/scala
-
Notifications
You must be signed in to change notification settings - Fork 3
Fix IncompatibleClassChangeError under Java 9 #24
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
Merged
smarter
merged 2 commits into
lampepfl:sharing-backend
from
dotty-staging:fix-java9-itf
Aug 25, 2018
Merged
Fix IncompatibleClassChangeError under Java 9 #24
smarter
merged 2 commits into
lampepfl:sharing-backend
from
dotty-staging:fix-java9-itf
Aug 25, 2018
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Sep 17, 2017
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
Corresponding Dotty PR: scala/scala3#3138 |
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Sep 17, 2017
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
10 tasks
Scalac 2.12.3 emits an
See: |
Thanks! I guess this answers my question: https://github.com/scala/scala/blob/32f597704698291b7162335844b366a20873c67b/src/compiler/scala/tools/nsc/backend/jvm/BTypesFromSymbols.scala#L76-L79, you're calling |
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Oct 12, 2017
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Oct 12, 2017
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
48e0589
to
6152e24
Compare
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Oct 12, 2017
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
The itf flag of `visitMethodInsn` and `Handle` in ASM needs to be true when the method is defined in an interface. Java 8 ignores this but Java 9 fails at runtime with: java.lang.IncompatibleClassChangeError: Method ... must beInterfaceMethodref constant This commit is inspired by similar changes in scalac, in particular see 7d51b3f by Jason Zaugg (from scala#5251) and e619b03 by Lukas Rytz (from scala#5293). This issue was also discussed in scala#5452 (which does not matter for Dotty since we do not run the backend optimizer).
smarter
added a commit
to dotty-staging/dotty
that referenced
this pull request
Aug 23, 2018
This commit temporarily changes .gitmodules until lampepfl/scala#24 is merged.
allanrenucci
approved these changes
Aug 24, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The itf flag of
visitMethodInsn
andHandle
in ASM needs to be truewhen the method is defined in an interface. Java 8 ignores this but Java
9 fails at runtime with:
java.lang.IncompatibleClassChangeError: Method ... must be InterfaceMethodref constant
This commit is inspired by similar changes in scalac, in particular see
7d51b3f by Jason Zaugg
(from scala#5251) and
e619b03 by Lukas Rytz
(from scala#5293). This issue was also
discussed in scala#5452 (which does not
matter for Dotty since we do not run the backend optimizer).