[concurrency-interest] weakCompareAndSet in atomics - incompatible class change?
tackline at tackline.plus.com
Sun Mar 4 14:41:34 EST 2007
Dawid Kurzyniec wrote:
> Question: isn't adding a final method to a non-final class an
> incompatible class change? It breaks subclasses containing a method with
> the same signature. What's the official view on this?
It's done all the time in the Java library. It an break things, but
rarely. SocketImpl even had an abstract method added in 1.4.
> work on 6.0. (I always thought that Atomic* classes should have been
> made final :P )
I see the atomic lasses as primarily there for low-level optimisation.
One such optimisation is opportunistic inheritance.
More information about the Concurrency-interest