Skip to content

Commit 0d5baba

Browse files
committed
Added links to std::net::AddrParseError's documentation
Additionally changed the summary sentence to be more consistent with most of the other FromStr implementations' error types.
1 parent df5830a commit 0d5baba

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

src/libstd/net/parser.rs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,19 @@ impl FromStr for SocketAddr {
368368
}
369369
}
370370

371-
/// An error returned when parsing an IP address or a socket address.
371+
/// An error which can be returned when parsing an IP address or a socket address.
372+
///
373+
/// This error is used as the error type for the [`FromStr`] implementation for
374+
/// [`IpAddr`], [`Ipv4Addr`], [`Ipv6Addr`], [`SocketAddr`], [`SocketAddrV4`], and
375+
/// [`SocketAddrV6`].
376+
///
377+
/// [`FromStr`]: ../../std/str/trait.FromStr.html
378+
/// [`IpAddr`]: ../../std/net/enum.IpAddr.html
379+
/// [`Ipv4Addr`]: ../../std/net/struct.Ipv4Addr.html
380+
/// [`Ipv6Addr`]: ../../std/net/struct.Ipv6Addr.html
381+
/// [`SocketAddr`]: ../../std/net/enum.SocketAddr.html
382+
/// [`SocketAddrV4`]: ../../std/net/struct.SocketAddrV4.html
383+
/// [`SocketAddrV6`]: ../../std/net/struct.SocketAddrV6.html
372384
#[stable(feature = "rust1", since = "1.0.0")]
373385
#[derive(Debug, Clone, PartialEq, Eq)]
374386
pub struct AddrParseError(());

0 commit comments

Comments
 (0)