mirror of
https://github.com/tokio-rs/tokio.git
synced 2025-09-25 12:00:35 +00:00
Set Sink types as must_use
This commit is contained in:
parent
bd9a07f3ad
commit
7624061021
@ -23,6 +23,7 @@ use reactor::{Handle, PollEvented};
|
||||
/// This type is created by the [`channel`] function.
|
||||
///
|
||||
/// [`channel`]: fn.channel.html
|
||||
#[must_use = "sinks do nothing unless polled"]
|
||||
pub struct Sender<T> {
|
||||
tx: channel::Sender<T>,
|
||||
}
|
||||
|
@ -55,6 +55,7 @@ pub trait UdpCodec {
|
||||
///
|
||||
/// You can acquire a `UdpFramed` instance by using the `UdpSocket::framed`
|
||||
/// adapter.
|
||||
#[must_use = "sinks do nothing unless polled"]
|
||||
pub struct UdpFramed<C> {
|
||||
socket: UdpSocket,
|
||||
codec: C,
|
||||
|
Loading…
x
Reference in New Issue
Block a user