Add try_read_buf and try_recv_buf #3313
Labels
A-tokio
Area: The main tokio crate
C-feature-accepted
Category: A feature request that has been accepted pending implementation.
C-feature-request
Category: A feature request.
E-help-wanted
Call for participation: Help is requested to fix this issue.
M-net
Module: tokio/net
Add
_buf
variants of thetry_recv
methods onTcpStream
,UnixStream
,UdpSocket
andUnixSocket
. These methods should have a signature similar toAsyncReadExt::read_buf
like this:For
TcpStream
andUnixStream
, the method should support reading into uninitialized memory. ForUdpSocket
andUnixSocket
, they should support receiving messages into uninitialized memory.The text was updated successfully, but these errors were encountered: