> Finish the thought, what happens when there is "contention", a thread 
> reads then writes before you acquire the lock to commit. You can try 
> and making locking work, but you'll just up with CAS based on a lock 
>
>
>
I am not saying to throw away the "swap!" syntax. "swap!" syntax guarantees 
that you if you want to change an atom value, you must start with its 
latest, current value. I am just saying we'd better exclude any other 
writer (swap!) from starting once a writer already started to work.

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to