Thanks guys for all the answers, I think I am going to stick with the simple 
code and no protection based on the arguments that I read. It will do for my 
application where nothing catastrophic will happen when in case of a clash.

On 03 Apr 2014, at 00:11, Sven Van Caekenberghe <s...@stfx.eu> wrote:

> Hi,
> 
> Is it possible to have a simple lock-free atomic counter in Pharo 3.0 ?
> 
> nextId
>  ^ idCounter := idCounter + 1
> 
> Or is it still possible that two process entering this code can mess things 
> up ?
> 
> I vaguely remember a discussion about that long ago...
> 
> TIA,
> 
> Sven


Reply via email to