Closed
Description
This doesn't compile with dotty:
class Foo @deprecated("foo", "2.11.0") (x: Int)
1 |class Foo @deprecated("foo", "2.11.0") (x: Int)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
| private, protected, or this expected for annotated primary constructor
Adding this
does indeed fix it, but doesn't compile with Scala 2:
class Foo @deprecated("foo", "2.11.0") this(x: Int)
- Is this an intentional difference?
- If yes, we should at least support the old syntax under
-language:Scala2