On May 11, 3:13 am, Mark Engelberg <mark.engelb...@gmail.com> wrote:
> I'm curious, wouldn't it be possible for every ref-set to be
> implicitly wrapped in a dosync?  That way, you wouldn't have to
> explictly wrap ref-set in a dosync for the times where you just want
> to change one ref.  You'd only need to explicitly call dosync when you
> need to wrap more than one ref-set in a transaction.

It would be possible, but also would be a great loss to give up the
error that ref-set/alter/commute was not in a transaction. I think it
is important that people explicitly state the minimum granularity of a
transaction. It is also important to support the definition of
transaction-required fns that don't start their own transactions -
i.e. they are designed to be composed and require the end user set up
(and be aware of) a transaction.

So, implicit transactions on the core primitives are a definite no-go.

Rich

--~--~---------~--~----~------------~-------~--~----~
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
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