Closed som-snytt closed 6 months ago
I would vote for "just use it".
Who knows how much Scala code uses @Deprecated
intentionally for whatever reasons
(e.g. some Scala library is supposed to be used from Java code)
I also think that "just use it" is reasonable. I've accidentally used the wrong @Deprecated
before and not noticed. Could I give this a go? I just forked scala/scala
and was looking for an issue to contribute on to learn the process. I think I see the code changes that need to happen for this and have a branch on my fork just using it:
scala> @Deprecated def f = 42
def f: Int
scala> f
^
warning: method f is deprecated
val res0: Int = 42
Reproduction steps
Scala version: 2.13.11
Problem
scalac
does nothing with@Deprecated
on Scala elements.It should either warn that it is a typo for
@deprecated
or just use it.Noticed at https://github.com/scala/bug/issues/12714#issuecomment-1677824530