[concurrency-interest] Re: AtomicInteger and AtomicLong should implement Number
Tue, 6 Jan 2004 15:09:20 +1000
Larry Riedel wrote:
> but it would still make sense to me to try to provide
> /some/ shared ancestor type which provides a /single/ way to get
> the value from an Integer /or/ an AtomicInteger.
The fact that this makes sense concerns me, because there was never an
intent to associate AtomicInteger with Integer or AtomicLong with
Long, or to suggest that one might ever want to replace an Integer by
an AtomicInteger etc. Will changing the names to AtomicIntValue and
AtomicLongValue break this association?
Would it also help clarify things if I said that what some people
really wanted to do was introduce an 'atomic' field modifier and
introduce a test-and-set operator, but there was no way that was going
to happen so we had to define the AtomicX classes?