Deprecate channel selection
This commit is contained in:
parent
653da4fd00
commit
d75dae3069
@ -399,6 +399,8 @@ macro_rules! await {
|
||||
/// For more information about select, see the `std::sync::mpsc::Select` structure.
|
||||
#[macro_export]
|
||||
#[unstable(feature = "mpsc_select", issue = "27800")]
|
||||
#[rustc_deprecated(since = "1.32.0",
|
||||
reason = "channel selection will be removed in a future release")]
|
||||
macro_rules! select {
|
||||
(
|
||||
$($name:pat = $rx:ident.$meth:ident() => $code:expr),+
|
||||
|
@ -124,6 +124,7 @@
|
||||
//! ```
|
||||
|
||||
#![stable(feature = "rust1", since = "1.0.0")]
|
||||
#![allow(deprecated)] // for mpsc_select
|
||||
|
||||
// A description of how Rust's channel implementation works
|
||||
//
|
||||
|
@ -51,11 +51,10 @@
|
||||
#![unstable(feature = "mpsc_select",
|
||||
reason = "This implementation, while likely sufficient, is unsafe and \
|
||||
likely to be error prone. At some point in the future this \
|
||||
module will likely be replaced, and it is currently \
|
||||
unknown how much API breakage that will cause. The ability \
|
||||
to select over a number of channels will remain forever, \
|
||||
but no guarantees beyond this are being made",
|
||||
module will be removed.",
|
||||
issue = "27800")]
|
||||
#![rustc_deprecated(since = "1.32.0",
|
||||
reason = "channel selection will be removed in a future release")]
|
||||
|
||||
|
||||
use fmt;
|
||||
|
@ -16,6 +16,7 @@
|
||||
// expose is still present.
|
||||
|
||||
#![feature(mpsc_select)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
use std::sync::mpsc::{channel, Sender, Receiver};
|
||||
use std::thread;
|
||||
|
Loading…
x
Reference in New Issue
Block a user