Hi,
I have the following problem:
I have a set of channels #{ ... }
some of the channels are closed, some of the channels are open
* for the channels that are open, I want to (>! chan msg)
* for the channels that are closed, I want to remove the channel from the
hash-set
## Problems:
(1) (>! ... ...) always returns nil, regardless of whether the channel is
open or closed, and thus useless
(2) I could use (<! ... ) to read from the channel to see if it's nil, but
then would remove an item from the channel, which I don't want to do
## Question:
Thus, without changing the state of the channel, is there a way to see if
the channel is open/closed?
Thanks!
--
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.