[erlang-questions] Selective receive issue
Tue Aug 5 15:11:39 CEST 2008
Thanks a lot for the detailed answer!
Unfortunately, it doesn't work for me (or at least not without a fundamental
redesign). The problem is that the process() function has to have its own
receive statement, because it may retrieve any number of messages (matching
different patterns) that will be processed at the current step.
Of course, this can be solved by buffering messages, but I rather wouldn't
do that. It makes the logic much more complex (and it's already not so
Another alternative would be to wrap this process in another one that will
pass on messages that will be recognized and discard any others. Or to
completely ignore the issue :-)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions