pub fn after_ms(duration: u32) -> Receiver<()> {
    #![allow(deprecated)]
    let (send, recv) = sync(0);
    thread::spawn(move || {
        thread::sleep_ms(duration);
        drop(send);
    });
    recv
}
/// Creates a new rendezvous channel that is dropped after a timeout.
///
/// `duration` is specified in milliseconds.
///
/// When the channel is dropped, any receive operation on the returned channel
/// will be unblocked.
///
/// N.B. This will eventually be deprecated when we get a proper duration type.
///
/// # Example
///
/// ```
/// let wait = chan::after_ms(1000);
/// // Unblocks after 1 second.
/// wait.recv();
/// ```
Creates a new rendezvous channel that is dropped after a timeout.
`duration` is specified in milliseconds.

When the channel is dropped, any receive operation on the returned channel
will be unblocked.


Creates a new rendezvous channel that is dropped after a timeout . ` duration ` is specified in milliseconds . When the channel is dropped any receive operation on the returned channel will be unblocked .
pub fn after_ms(duration: u32) -> Receiver<()> {
    #![allow(deprecated)]
    let (send, recv) = sync(0);
    thread::spawn(move || {
        thread::sleep_ms(duration);
        drop(send);
    });
    recv
}
pub fn after_ms ( duration : u32 ) -> Receiver < ( ) > { # ! [ allow ( deprecated ) ] let ( send , recv ) = sync ( 0 ) ; thread :: spawn ( move | | { thread :: sleep_ms ( duration ) ; drop ( send ) ; } ) ; recv }
Creates a new rendezvous channel that is dropped after a timeout.
Creates a new rendezvous channel that is dropped after a timeout .
duration
u32
duration
u32
example
```
let wait = chan::after_ms(1000);
Unblocks after 1 second.
` ` ` let wait = chan :: after_ms ( 1000 ) ; Unblocks after 1 second .