On Mon, Jan 12, 2009 at 5:15 AM, Tom Ayerst <tom.aye...@gmail.com> wrote: > For example, I am pretty sure I don't need to wrap 'send' in 'dosync' (it > works without it).
Right. dosync starts a transaction. Agents and Atoms aren't affected by transactions. You only need dosync when working with Refs. > 2009/1/12 Tom Ayerst <tom.aye...@gmail.com> >> >> Hi, >> >> Following in a growing tradition I have written YACS (Yet Another Clojure >> Snake); this one uses an Agent to hold the state and has separate GUI and >> model threads using >> invokeLater to update the GUI from the model in a thread safe way. At >> least that was the plan. >> >> My specific aims were to practice use a more complex agent and to >> comunicate with the EDT correctly. >> >> I would very much appreciate any comments on the correctness (especially >> of the agent code) and of any Clojure idioms I could have used to simplify >> or improve it. -- R. Mark Volkmann Object Computing, Inc. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---