[erlang-questions] Selective receive issue

Vlad Dumitrescu vladdu55@REDACTED
Tue Aug 5 15:11:39 CEST 2008


Hi Cristoph!

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
simple :-)

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 :-)

best regards,
Vlad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20080805/6a0e7b88/attachment.htm>


More information about the erlang-questions mailing list