-
Notifications
You must be signed in to change notification settings - Fork 21
ArrayBuffer in 2.13.13 not binary compatible with ArrayBuffer 2.13.12 #13021
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
Comments
Midnight here, so I'm not sure where your report was, but I do remember an old paulp ticket complaining about lack of enforcement for Is a lint called for, to warn about migration-unsafety of |
Overriding (and accessing) |
So do we agree that this ticket should be closed as not-a-bug, since the class in question was private to a @noresttherein I'm curious how you even ran into this? |
Yes, afaict this is not-a-bug. |
Here is the ticket on why overriding I made that mistake in my midnight comment. This is a MiMa bug. And |
how so? |
The qualified private member is public in bytecode. Or does MiMa not care because everything is public in bytecode. |
So I wonder if this is more of a source compatibility, not binary compatibility. compiles in Scala 2.13.12package example
class A[A1] extends scala.collection.mutable.ArrayBuffer[A1] {
override def ensureAdditionalSize(size: Int): Unit =
println(s"hihi $size")
} On Scala 2.13.13 you get:
compiles in Scala 2.13.13package example
class A[A1] extends scala.collection.mutable.ArrayBuffer[A1] {
def ensureAdditionalSize(size: Int): Unit =
println(s"hihi $size")
} |
Yes, what I meant to say is that it's so annoying when Seth reminds me that MiMa is for binary not source compat. I also went over to the project site to re-read the Readme. Sorry for the misdirection. It's still true that |
Scala version: 2.13.13
In
2.13.12
and before,ArrayBuffer
has methodProblem
It is no longer present in
2.13.13
, being replaced with regular ensureSize.I would like to point out that when I reported that overriding
protected[name]
methods is possible by classes outside the package (which came as a surprise), it was deemed to work as intended and a perfectly fine situation, so the irony bites me in my behind.Proly a
@deprecatedOverriding
would be safer for at least one version.The text was updated successfully, but these errors were encountered: