Skip to content

Commit d6caa64

Browse files
author
Jonathan Turner
authored
Rollup merge of rust-lang#35175 - frewsxcv:tcp, r=GuillaumeGomez
A couple `std::net` doc improvements. None
2 parents 746427f + f2d8db1 commit d6caa64

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

src/libstd/net/mod.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ mod udp;
3535
mod parser;
3636
#[cfg(test)] mod test;
3737

38-
/// Possible values which can be passed to the `shutdown` method of `TcpStream`.
38+
/// Possible values which can be passed to the [`shutdown`] method of
39+
/// [`TcpStream`].
40+
///
41+
/// [`shutdown`]: struct.TcpStream.html#method.shutdown
42+
/// [`TcpStream`]: struct.TcpStream.html
3943
#[derive(Copy, Clone, PartialEq, Debug)]
4044
#[stable(feature = "rust1", since = "1.0.0")]
4145
pub enum Shutdown {

src/libstd/net/tcp.rs

+5
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,11 @@ pub struct TcpListener(net_imp::TcpListener);
7777
///
7878
/// This iterator will infinitely yield `Some` of the accepted connections. It
7979
/// is equivalent to calling `accept` in a loop.
80+
///
81+
/// This `struct` is created by the [`incoming`] method on [`TcpListener`].
82+
///
83+
/// [`incoming`]: struct.TcpListener.html#method.incoming
84+
/// [`TcpListener`]: struct.TcpListener.html
8085
#[stable(feature = "rust1", since = "1.0.0")]
8186
pub struct Incoming<'a> { listener: &'a TcpListener }
8287

0 commit comments

Comments
 (0)