Documentation: https://doc.rust-lang.org/clippy/attribs.html#clippyhas_significant_drop
If significant_drop_in_scrutinee lint is enabled, a warning would be generated about an un-intuitive behavior of temporaries in match scrutinees that might lead to deadlocks:
match make_query(&pool.get().await.unwrap()) {
Ok(_) => {
// Connection still not returned to the pool!
}
...
};
// Connection is only released here
See also: rust-lang/rust#93883
Documentation: https://doc.rust-lang.org/clippy/attribs.html#clippyhas_significant_drop
If significant_drop_in_scrutinee lint is enabled, a warning would be generated about an un-intuitive behavior of temporaries in
matchscrutinees that might lead to deadlocks:See also: rust-lang/rust#93883