Don't fire rust_2021_incompatible_closure_captures in edition = 2021
This commit is contained in:
parent
b11bf65e4a
commit
fcd42d628c
3 changed files with 21 additions and 2 deletions
15
src/test/ui/lint/issue-101284.rs
Normal file
15
src/test/ui/lint/issue-101284.rs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
// check-pass
|
||||
// edition:2021
|
||||
#![deny(rust_2021_compatibility)]
|
||||
|
||||
pub struct Warns {
|
||||
// `Arc` has significant drop
|
||||
_significant_drop: std::sync::Arc<()>,
|
||||
field: String,
|
||||
}
|
||||
|
||||
pub fn test(w: Warns) {
|
||||
_ = || drop(w.field);
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
Loading…
Add table
Add a link
Reference in a new issue