If one used those preds to try putting values on the channels one is asking about, then yes, that would generate a classic nasty check-then-act scenario:
(when-not (closed? c) (>! c 42)) ;; Value could be never put, in face of interleavings Programmers experienced in concurrency should have developed a sensibility against that kind of code anyway. However, if what one is trying is to *stop* putting values on the channel, I see no possible race conditions. On Friday, July 12, 2013 2:01:02 AM UTC+2, Brandon Bloom wrote: > > Wouldn't closed and drained predicates introduce race conditions? > > (Sorry for brevity, on my phone) > -- -- 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 --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.