rust/src/test/ui/nll/unused-mut-issue-50343.rs
2018-12-25 21:08:33 -07:00

8 lines
163 B
Rust

#![feature(nll)]
#![deny(unused_mut)]
fn main() {
vec![(42, 22)].iter().map(|(mut x, _y)| ()).count();
//~^ ERROR: variable does not need to be mutable
}