-
Notifications
You must be signed in to change notification settings - Fork 21
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
new "cyclic aliasing or subtype" error in 2.13 #12622
Comments
Putting on "Backlog" since there hasn't been any activity in quite some time — @retronym let us know if this should be prioritized for 2.13.11 |
I wonder if this bug is related to this other one zio/zio-prelude#1183 |
@abebeos probably it's not necessary to at-mention, especially on a stale ticket. I think (or assume) this ticket is a balance between stabilization (a feature) and possible limitations (regressions). A feature can be worth a regression, even if the regression is not a quick fix. To your other questions, I think retronym (and others) have custom tooling (with custom args). Sometimes they demonstrate them in tickets, just to maintain an aura of mystery.
|
The reproduction is as shown. I tested a year ago locally with no options. In showing a reproduction, it's necessary to indicate which version was used. 2.13.12 has the same result. latest scala 2
It works for me scala 3 rejects the reproduction outright because of projections. One may say projectile projections. As Seth would ask, why are you asking? Do you have a problem with your project, or did you think this looks like a fun issue to solve? |
In general, I second Som's remarks. I would not describe our attitude towards regressions as "casual".
Ideally, yes. In practice, things slip through sometimes, even though we have an enormous test suite in scala/scala, and even though we have also put substantial engineering effort into creating the Scala 2 community build to catch regressions.
In a perfect world, sure. In practice, sometimes a big step forward is worth a small step backward, especially if the step backwards is 1) small in the sense that we expect not many users will be affected, and 2) it isn't clear how the problem can be addressed. In simple enough projects, it might be feasible to have a stricter policy, as you would like. But the complexity of the Scala 2 type checker well exceeds any plausible definition of "simple enough". In short, we don't regret merging scala/scala#5999. Despite this ticket, in our judgment the benefit still substantially exceeds the cost. Note that 5999 was merged in 2018, and the regression wasn't even noticed until 3.5 years later. Nor we do regret leaving the regression provisionally unfixed, though we would certainly welcome a fix. Perhaps you'd like to look into it yourself...? |
Reproduction steps
The relevant change in 2.13 appears to be scala/scala#5999 (stabilising vals)
scalac -Yrecursion 1
avoids all errors in both 2.12 and 2.13.The text was updated successfully, but these errors were encountered: