fix(tcp): remove redundant format! macro call

This commit is contained in:
Sergei Belokon 2023-04-08 08:19:47 +10:00
parent 502cb6f4b9
commit 081e222d99

View File

@ -869,7 +869,7 @@ pub fn incoming(&self) -> Incoming<'_> {
/// use std::net::{TcpListener, TcpStream}; /// use std::net::{TcpListener, TcpStream};
/// ///
/// fn listen_on(port: u16) -> impl Iterator<Item = TcpStream> { /// fn listen_on(port: u16) -> impl Iterator<Item = TcpStream> {
/// let listener = TcpListener::bind(format!("127.0.0.1:{port}")).unwrap(); /// let listener = TcpListener::bind(("127.0.0.1", port)).unwrap();
/// listener.into_incoming() /// listener.into_incoming()
/// .filter_map(Result::ok) /* Ignore failed connections */ /// .filter_map(Result::ok) /* Ignore failed connections */
/// } /// }