Feature Request P2
Status Update
Comments
em...@google.com <em...@google.com> #2
That seems like a big limitation because it means that to get lint checks on them you need to add them to the base but then they are also packaged with the base instead of the dynamic-features. Can we attempt to fix this for 7.1?
em...@google.com <em...@google.com>
ap...@google.com <ap...@google.com> #3
Ok, yes, I can attempt to fix for 7.1.
ap...@google.com <ap...@google.com> #4
thanks!
Description
Sealed classes and interfaces cannot be extended directly outside their module. Intuitively this implies they are effectively final, and therefore otherwise incompatible changes would be allowed, such as adding a new abstract method.
Unfortunately, it's possible to extend a sealed class with an abstract class as below and inadvertently expose a new abstract method (
funFromSealed()
in the example below). We should figure out how we want to model this behavior in Metalava, figure out if there's any other considerations to sealed classes, and then maybe updateClassItem.isEffectivelyFinal()
to match.