mozilla/rust — pull request #1847 by brson (2012-02-15 08:03:12+00:00)
Title: Selecting from multiple ports

This adds a function to the runtime that selects the next port with available messages from an arbitrary list of ports. In Rust it's rather harder to type an arbitrary list of ports, but this does add a `comm::select2` function to receive from 2 ports. This is enough to enable a number of useful scenarios.

Once we have task local data this will allow us to hide a control port in the task and move things like linked failure and notifications out of the runtime and into core.