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
To aid cross building, allow ?
as a wildcard even without -Xsource:3
#9990
Conversation
Like scala#9721, the goal here is to ease cross-compilation between Scala 2 and 3 code as we prepare for `_` as wildcard to be deprecated in Scala 3 (cf scala/scala3#5379). This is technically a source-breaking change, but using a type named ? without backticks is deprecated since 2.13.6 (scala#9626) and defining a type named ? without backticks is disallowed since 2.13.7 (scala#9735). The only known user of ? as a type name was the kind-projector plugin, but support for this syntax was removed from the plugin a year ago (typelevel/kind-projector#186), so I believe this change won't be disruptive.
SGTM. @dwijnand, @SethTisue? |
Any opinion on this before I open a PR? |
I'm happy with that plan. |
This backports scala#9990 to Scala 2.12 as discussed in that PR.
opened typelevel/kind-projector#210 to notify the kind-projector folks |
I've opened a PR to temporarily revert scalameta/scalameta#2733 until 2.12.16 and 2.13.9 are released, as source code generation is now broken for all releases in the 2.12 and 2.13 lines. Once the releases are cut, there's a follow-up PR to reintroduce the new Broadcasting intent here, in case others run into the same issue I did, no longer being able to generate code that compiles with the currently released latest versions of either 2.12 or 2.13. |
?
as a wildcard even without -Xsource:3
Like #9721, the goal here is to ease cross-compilation between Scala 2 and 3 code as we prepare for
_
as wildcard to be deprecated in Scala 3 (cf scala/scala3#5379).This is technically a source-breaking change, but using a type named
?
without backticks is deprecated since 2.13.6 (#9626) and defining a type named?
without backticks is disallowed since 2.13.7 (#9735). The only known user of?
as a type name was the kind-projector plugin, but support for this syntax was removed from the plugin a year ago (typelevel/kind-projector#186), so I believe this change won't be disruptive.