Re: GetAndSet function (corresponding to cas function)

2011-12-27 Thread Adrian Mercieca
On Mon, 26 Dec 2011 15:06:57 -0600, Andrew Wiley wrote: On Mon, Dec 26, 2011 at 2:34 PM, Adrian Mercieca amerci...@gmail.com wrote: Hi folks, Would anyone answer me on this please? To clarify, in Java there is are getAndSet methods on Atomic type objects (along with compareAndSet). I

Re: GetAndSet function (corresponding to cas function)

2011-12-27 Thread Adrian Mercieca
Hi Andrew, Actually, what would be the equivalent of the 'get' function in D? Thanks.

Re: GetAndSet function (corresponding to cas function)

2011-12-26 Thread Adrian Mercieca
Hi folks, Would anyone answer me on this please? To clarify, in Java there is are getAndSet methods on Atomic type objects (along with compareAndSet). I know that in D there is the cas function (equivalent to Java's compareAndSet); is there an equivalent D function for Java's getAndSet

Re: GetAndSet function (corresponding to cas function)

2011-12-26 Thread Andrew Wiley
On Mon, Dec 26, 2011 at 2:34 PM, Adrian Mercieca amerci...@gmail.com wrote: Hi folks, Would anyone answer me on this please? To clarify, in Java there is are getAndSet methods on Atomic type objects (along with compareAndSet). I know that in D there is the cas function (equivalent to

Re: GetAndSet function (corresponding to cas function)

2011-12-26 Thread Jonathan M Davis
On Monday, December 26, 2011 20:34:39 Adrian Mercieca wrote: Hi folks, Would anyone answer me on this please? To clarify, in Java there is are getAndSet methods on Atomic type objects (along with compareAndSet). I know that in D there is the cas function (equivalent to Java's

Re: GetAndSet function (corresponding to cas function)

2011-12-26 Thread Andrew Wiley
On Mon, Dec 26, 2011 at 4:05 PM, Jonathan M Davis jmdavisp...@gmx.com wrote: On Monday, December 26, 2011 20:34:39 Adrian Mercieca wrote: Hi folks, Would anyone answer me on this please? To clarify, in Java there is are getAndSet methods on Atomic type objects (along with compareAndSet).

GetAndSet function (corresponding to cas function)

2011-12-25 Thread Adrian Mercieca
Hi folks, Is there a GetAndSet function (corresponding to cas (compare and set) function) in D? Thanks.

Re: GetAndSet function (corresponding to cas function)

2011-12-25 Thread Mike Wey
On 12/25/2011 09:25 AM, Adrian Mercieca wrote: Hi folks, Is there a GetAndSet function (corresponding to cas (compare and set) function) in D? Thanks. core.atomic.cas http://dlang.org/phobos/core_atomic.html#cas -- Mike Wey

Re: GetAndSet function (corresponding to cas function)

2011-12-25 Thread Adrian Mercieca
On Sun, 25 Dec 2011 13:37:32 +0100, Mike Wey wrote: On 12/25/2011 09:25 AM, Adrian Mercieca wrote: Hi folks, Is there a GetAndSet function (corresponding to cas (compare and set) function) in D? Thanks. core.atomic.cas http://dlang.org/phobos/core_atomic.html#cas I know of the cas