mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-30 00:00:16 +02:00
runtime: mark EnterGuard with must_use (#3609)
This commit is contained in:
@@ -39,6 +39,7 @@ pub struct Handle {
|
|||||||
///
|
///
|
||||||
/// [`Runtime::enter`]: fn@crate::runtime::Runtime::enter
|
/// [`Runtime::enter`]: fn@crate::runtime::Runtime::enter
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
|
#[must_use = "Creating and dropping a guard does nothing"]
|
||||||
pub struct EnterGuard<'a> {
|
pub struct EnterGuard<'a> {
|
||||||
handle: &'a Handle,
|
handle: &'a Handle,
|
||||||
guard: context::EnterGuard,
|
guard: context::EnterGuard,
|
||||||
|
|||||||
Reference in New Issue
Block a user