Emit mixin-related methods as artifacts, mixin forwarders as bridges#6141
Merged
odersky merged 3 commits intoscala:masterfrom Mar 22, 2019
Merged
Emit mixin-related methods as artifacts, mixin forwarders as bridges#6141odersky merged 3 commits intoscala:masterfrom
odersky merged 3 commits intoscala:masterfrom
Conversation
Mixin forwarders are now emitted unconditionally and without generic signatures, this broke lsp4j and therefore our language server, emitting mixin forwards with the Artifact flag (which remember corresponds to SYNTHETIC in Java bytecode) unbreaks lsp4j, and it seems reasonable to use this for all the forwarders we generate for traits, including super-accessors.
8ded6fb to
3390d07
Compare
This seems to match the behavior of Scala 2.13 and more importantly it will be needed after the next commit that emits mixin forwarders as bridges, otherwise `extends App` won't work.
This is the same scheme I proposed in scala/scala#7843 which sidesteps all the issues regarding mixin forwarders and generic signatures, see the discussion in that PR for more information. Tests imported from scalac, some of the comments in them might not be correct for Dotty anymore.
odersky
approved these changes
Mar 22, 2019
hamzaremmal
added a commit
that referenced
this pull request
Jul 27, 2025
Forward port of scala/scala#8037 Reverts #6352 and #6141. Fixes #19270.
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
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.
And in the process fix the language server (see #6128)