Skip to main content

selective_receive

Function selective_receive 

Source
pub fn selective_receive() -> Chunk
Expand description

Selective Atomic Hop: server waits for TAG_REQ while a TAG_JUNK hop sits ahead in the mailbox (FIFO skip, not drop).

Requires crate::std_native_table.

  1. main sends junk (tag=TAG_JUNK), then request (tag=TAG_REQ, payload=41)
  2. server does ReceiveMatchImm TAG_REQ ÔÇö must see payload 41, not junk
  3. replies TAG_REP / 42; then classic Receive drains the leftover junk
  4. main returns reply payload 42