@@ -65,16 +65,14 @@ pub struct TcpStream(net_imp::TcpStream);
65
65
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
66
66
pub struct TcpListener ( net_imp:: TcpListener ) ;
67
67
68
- /// An infinite iterator over the connections from a `TcpListener`.
69
- ///
70
- /// This iterator will infinitely yield [`Some`] of the accepted connections. It
71
- /// is equivalent to calling `accept` in a loop.
68
+ /// An iterator that infinitely [`accept`]s connections on a [`TcpListener`].
72
69
///
73
70
/// This `struct` is created by the [`incoming`] method on [`TcpListener`].
71
+ /// See its documentation for more.
74
72
///
75
- /// [`Some `]: ../../std/option/enum.Option .html#variant.Some
76
- /// [`incoming`]: struct.TcpListener.html#method.incoming
77
- /// [`TcpListener`]: struct.TcpListener.html
73
+ /// [`accept `]: ../../std/net/struct.TcpListener .html#method.accept
74
+ /// [`incoming`]: ../../std/net/ struct.TcpListener.html#method.incoming
75
+ /// [`TcpListener`]: ../../std/net/ struct.TcpListener.html
78
76
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
79
77
#[ derive( Debug ) ]
80
78
pub struct Incoming < ' a > { listener : & ' a TcpListener }
@@ -583,10 +581,12 @@ impl TcpListener {
583
581
/// listener.
584
582
///
585
583
/// The returned iterator will never return [`None`] and will also not yield
586
- /// the peer's [`SocketAddr`] structure.
584
+ /// the peer's [`SocketAddr`] structure. Iterating over it is equivalent to
585
+ /// calling [`accept`] in a loop.
587
586
///
588
587
/// [`None`]: ../../std/option/enum.Option.html#variant.None
589
588
/// [`SocketAddr`]: ../../std/net/enum.SocketAddr.html
589
+ /// [`accept`]: #method.accept
590
590
///
591
591
/// # Examples
592
592
///
0 commit comments