-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Arguments should be lifted in explicit constructor calls of annotation classes #22526
Comments
Not sure how we could differentiate |
I'm more worried about the fact that the evaluation order is not preserved here... |
In the Scala 2 PR I added a typer mode: scala/scala#10976 |
Yes yes, that's the point of this issue 😄 |
In Dotty, I've been told a few times not to add The documentation of And passing a parameter from Would you have an opinion about that @dwijnand? (Asking you because you wrote the doc comment of Higher-level question: is there a use-case for this? Couldn't we just forbid creating annotation instances explicitly? |
No strong opinion. I feel like I wrote what Martin wrote elsewhere (on Slack maybe?). I guess we just create an internal setting and set it. |
Make it a Long? |
Compiler version
Scala 3.7.0-RC1-bin-20250204-d75ca7f-NIGHTLY
Minimized code
I fixed a bug in (#22035) where arguments were lifted, breaking assumptions later in the compiler.
However I haven't special-cased it for explicit constructor calls, so we currently get:
Arguably, the arguments should still be lifted when the instance is constructed explicitly, as in
b
above.The text was updated successfully, but these errors were encountered: