diff options
| author | lukaramu <lukaramu@gmail.com> | 2017-03-26 16:12:27 +0200 |
|---|---|---|
| committer | lukaramu <lukaramu@gmail.com> | 2017-03-26 16:12:27 +0200 |
| commit | ad816f81748e6314b428a91352b0eb536f7fffc5 (patch) | |
| tree | 42315457e4fc9842ab24ffbdd995140b80847432 /src/libstd | |
| parent | 1a9c8baed55547593610eb935c9cceccec40fdb4 (diff) | |
| download | rust-ad816f81748e6314b428a91352b0eb536f7fffc5.tar.gz rust-ad816f81748e6314b428a91352b0eb536f7fffc5.zip | |
Added links to std::net::Shutdown docs and made them more consistent
Part of #29363
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/net/mod.rs | 25 |
1 files changed, 19 insertions, 6 deletions
diff --git a/src/libstd/net/mod.rs b/src/libstd/net/mod.rs index b0d2e3e4687..e4593cf3817 100644 --- a/src/libstd/net/mod.rs +++ b/src/libstd/net/mod.rs @@ -43,17 +43,30 @@ mod test; #[derive(Copy, Clone, PartialEq, Eq, Debug)] #[stable(feature = "rust1", since = "1.0.0")] pub enum Shutdown { - /// Indicates that the reading portion of this stream/socket should be shut - /// down. All currently blocked and future reads will return `Ok(0)`. + /// The reading portion of the [`TcpStream`] should be shut down. + /// + /// All currently blocked and future [reads] will return [`Ok(0)`]. + /// + /// [`TcpStream`]: ../../std/net/struct.TcpStream.html + /// [reads]: ../../std/io/trait.Read.html + /// [`Ok(0)`]: ../../std/result/enum.Result.html#variant.Ok #[stable(feature = "rust1", since = "1.0.0")] Read, - /// Indicates that the writing portion of this stream/socket should be shut - /// down. All currently blocked and future writes will return an error. + /// The writing portion of the [`TcpStream`] should be shut down. + /// + /// All currently blocked and future [writes] will return an error. + /// + /// [`TcpStream`]: ../../std/net/struct.TcpStream.html + /// [writes]: ../../std/io/trait.Write.html #[stable(feature = "rust1", since = "1.0.0")] Write, - /// Shut down both the reading and writing portions of this stream. + /// Both the reading and the writing portions of the [`TcpStream`] should be shut down. + /// + /// See [`Shutdown::Read`] and [`Shutdown::Write`] for more information. /// - /// See `Shutdown::Read` and `Shutdown::Write` for more information. + /// [`TcpStream`]: ../../std/net/struct.TcpStream.html + /// [`Shutdown::Read`]: #variant.Read + /// [`Shutdown::Write`]: #variant.Write #[stable(feature = "rust1", since = "1.0.0")] Both, } |
