If a sealed class is marked as `Immutable` are all...
# compose
e
If a sealed class is marked as
Immutable
are all of its subclasses considered
Immutable
as well?
👀 1
j
I think not. Sealed or not, the fact a super class is
Immutable
tells you nothing about the contract for the subclasses.
Therefore, you would need to mark each class individually.
🙏 1
e
@jim is this still the case? In https://kotlinlang.slack.com/archives/CJLTWPH7S/p1637743593403000?thread_ts=1637743593.403000&cid=CJLTWPH7S @Csaba Kozák pointed out that the compiler seems to be marking classes as stable if they have a supertype that is stable.