distributed-process icon indicating copy to clipboard operation
distributed-process copied to clipboard

Document the semantics of receiveWait and similar

Open facundominguez opened this issue 10 years ago • 1 comments

Currently the documentation reads:

-- | Test the matches in order against each message in the queue
receiveWait :: [Match b] -> Process b Source

This is not sufficient, I think, to understand how receiveWait works in the presence of multiple messages in the mailbox and multiple match clauses. The order in which matches are done should be stated less succinctly.

I suppose we should also say that this function:

  • blocks when no message matches
  • it is interruptible when no message matches (can it be interrupted even if some message matches?).

facundominguez avatar Nov 02 '15 12:11 facundominguez

it is interruptible when no message matches (can it be interrupted even if some message matches?).

Yes, and we need to point out that if it is interrupted even if some message matches, the mailbox is not modified...

hyperthunk avatar Mar 01 '16 13:03 hyperthunk