You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've designed a struct that can't across the pending point for some specified api. So I deny clippy::await_holding_invalid_type but manually allow the this lint in some cases. But it seems doesn't work.
#![deny(clippy::await_holding_invalid_type)]
struct A {} // invalid type
struct B;
async fn do_a(_a: &mut A) -> B {
B
}
#[tokio::main]
async fn main() {
let _v = {
#[allow(clippy::await_holding_invalid_type)] // doesn't work.
let mut _a = A {};
#[allow(clippy::await_holding_invalid_type)] // doesn't work.
let b = &mut _a;
#[allow(clippy::await_holding_invalid_type)] // doesn't work.
do_a(b).await
};
}
Description
I've designed a struct that can't across the pending point for some specified api. So I deny clippy::await_holding_invalid_type but manually allow the this lint in some cases. But it seems doesn't work.
Version
Additional Labels
No response
The text was updated successfully, but these errors were encountered: