Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions library/std/src/os/net/linux_ext/tcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,7 @@ pub trait TcpStreamExt: Sealed {
///
/// # Examples
///
/// ```no run
/// #![feature(tcp_deferaccept)]
/// ```no_run
/// use std::net::TcpStream;
/// use std::os::linux::net::TcpStreamExt;
/// use std::time::Duration;
Expand All @@ -83,7 +82,7 @@ pub trait TcpStreamExt: Sealed {
/// .expect("Couldn't connect to the server...");
/// stream.set_deferaccept(Duration::from_secs(1u64)).expect("set_deferaccept call failed");
/// ```
#[unstable(feature = "tcp_deferaccept", issue = "119639")]
#[stable(feature = "tcp_deferaccept", since = "CURRENT_RUSTC_VERSION")]
#[cfg(target_os = "linux")]
fn set_deferaccept(&self, accept: Duration) -> io::Result<()>;

Expand All @@ -94,7 +93,6 @@ pub trait TcpStreamExt: Sealed {
/// # Examples
///
/// ```no_run
/// #![feature(tcp_deferaccept)]
/// use std::net::TcpStream;
/// use std::os::linux::net::TcpStreamExt;
/// use std::time::Duration;
Expand All @@ -104,7 +102,7 @@ pub trait TcpStreamExt: Sealed {
/// stream.set_deferaccept(Duration::from_secs(1u64)).expect("set_deferaccept call failed");
/// assert_eq!(stream.deferaccept().unwrap(), Duration::from_secs(1u64));
/// ```
#[unstable(feature = "tcp_deferaccept", issue = "119639")]
#[stable(feature = "tcp_deferaccept", since = "CURRENT_RUSTC_VERSION")]
#[cfg(target_os = "linux")]
fn deferaccept(&self) -> io::Result<Duration>;
}
Expand Down
Loading