2021-03-21 23:45:38 -05:00
|
|
|
// run-pass
|
|
|
|
|
2021-06-29 08:35:15 -05:00
|
|
|
#![warn(rust_2021_incompatible_closure_captures)]
|
2023-05-19 04:25:35 -05:00
|
|
|
#![allow(dropping_references, dropping_copy_types)]
|
2021-03-21 23:45:38 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
if let a = "" {
|
2021-06-29 08:35:15 -05:00
|
|
|
//~^ WARNING: irrefutable `if let` pattern
|
2021-03-21 23:45:38 -05:00
|
|
|
drop(|_: ()| drop(a));
|
|
|
|
}
|
|
|
|
}
|