diff options
author | Alice Ryhl <alice@ryhl.io> | 2020-10-02 06:13:28 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-01 21:13:28 -0700 |
commit | 7ec6d88b21ea3e5531176f526a51dae0a4513025 (patch) | |
tree | 6b4f289567fce7033551910c684c8358da4a58d8 /tokio/src/net | |
parent | 13de30c53eb90a5453f1cecf47b188e254a293ac (diff) |
chore: make #[doc(hidden)] apis private (#2901)
Diffstat (limited to 'tokio/src/net')
-rw-r--r-- | tokio/src/net/tcp/stream.rs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/tokio/src/net/tcp/stream.rs b/tokio/src/net/tcp/stream.rs index 99f77d41..f35f8b0c 100644 --- a/tokio/src/net/tcp/stream.rs +++ b/tokio/src/net/tcp/stream.rs @@ -192,9 +192,13 @@ impl TcpStream { Ok(TcpStream { io }) } - // Connects `TcpStream` asynchronously that may be built with a net2 `TcpBuilder`. - // - // This should be removed in favor of some in-crate TcpSocket builder API. + /// Connects `TcpStream` asynchronously that may be built with a net2 `TcpBuilder`. + /// + /// This function is intended to be replaced with some sort of TcpSocket builder. + /// See https://github.com/tokio-rs/tokio/issues/2902 + /// + /// Despite being hidden, this function is part of the public API of Tokio v0.3, but + /// will be removed in v1.0 in favor of a better design. #[doc(hidden)] pub async fn connect_std(stream: net::TcpStream, addr: &SocketAddr) -> io::Result<TcpStream> { let io = mio::net::TcpStream::connect_stream(stream, addr)?; |