Elastica icon indicating copy to clipboard operation
Elastica copied to clipboard

Mark classes as final

Open franmomu opened this issue 3 years ago • 1 comments

Thinking about 8.0 I think we should mark as many classes as possible with @final to let the user know that they will become final in 8.0. This will ease the maintenance (reducing the number of possible BC breaks) and we can always revert this if there are valid use cases.

franmomu avatar Jul 19 '22 14:07 franmomu

I'm torn on this proposal. I see the benefit around maintenance. At the same time it removes flexibility. Every time someone wants to extend a function / class we didn't expect to be extended for their own benefit, a new release is needed. Instead if we go with extendable by default, there is a risk that some changes on our end might break things for this users if we get more strict. We had recently a few of these cases where we did kind of breaking changes but so far I don't think we have heard of any place where it actually was a breaking change.

I think both paths will work and lets discuss a bit more what is the right one for Elastica. What kind of classes did you plan to mark as final?

ruflin avatar Aug 11 '22 11:08 ruflin