mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
9 lines
254 B
Rust
9 lines
254 B
Rust
//@ run-rustfix
|
|
fn main() {
|
|
let v = vec![1, 2, 3, 4, 5, 6, 7, 8, 9];
|
|
let vr = v.iter().filter(|x| {
|
|
*x % 2 == 0
|
|
//~^ ERROR cannot calculate the remainder of `&&{integer}` divided by `{integer}`
|
|
});
|
|
println!("{:?}", vr);
|
|
}
|