未验证 提交 049ba0c6 编写于 作者: D Dylan DPC 提交者: GitHub

Rollup merge of #77042 - imbolc:patch-2, r=kennytm

Improve documentation for ToSocketAddrs

I little clarification
......@@ -745,9 +745,9 @@ fn hash<H: hash::Hasher>(&self, s: &mut H) {
/// `(`[`Ipv4Addr`]`, `[`u16`]`)`, `(`[`Ipv6Addr`]`, `[`u16`]`)`:
/// [`to_socket_addrs`] constructs a [`SocketAddr`] trivially.
///
/// * `(`[`&str`]`, `[`u16`]`)`: the string should be either a string representation
/// * `(`[`&str`]`, `[`u16`]`)`: [`&str`] should be either a string representation
/// of an [`IpAddr`] address as expected by [`FromStr`] implementation or a host
/// name.
/// name. [`u16`] is the port number.
///
/// * [`&str`]: the string should be either a string representation of a
/// [`SocketAddr`] as expected by its [`FromStr`] implementation or a string like
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册