3 ms·
Don't forget sealed interfaces! I would say the killer features are records and pattern matching. Sealed interfaces/classes seem to mostly compensate for hype
by sshine 2mo ago
Don't forget sealed interfaces!
I would say the killer features are records and pattern matching.
Sealed interfaces/classes seem to mostly compensate for hypermobility caused by inheritance (that you can modify a superclass'es behavior and break abstraction boundaries).
Stop relying on inheritance, and you don't really need sealed interfaces.
Using records and thus lowering mutable state makes the problem of breaking abstraction boundaries lesser as well.
This is a hot take paid for by the functional programming lobby.