Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ignore bool_to_int_with_if clippy lint in test suite
error: boolean to int conversion using if --> tests/test_ensure.rs:620:30 | 620 | let test = || Ok(ensure!(if let ref mut _x @ 0 = 0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let ref mut _x @ 0 = 0))` | = note: `-D clippy::bool-to-int-with-if` implied by `-D clippy::all` = note: `!(let ref mut _x @ 0 = 0) as i32` or `(!(let ref mut _x @ 0 = 0)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:626:30 | 626 | let test = || Ok(ensure!(if let -1..=1 = 0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let -1..=1 = 0))` | = note: `!(let -1..=1 = 0) as i32` or `(!(let -1..=1 = 0)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:632:30 | 632 | let test = || Ok(ensure!(if let &0 = &0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!($lit))` | = note: `!($lit) as i32` or `(!($lit)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:638:30 | 638 | let test = || Ok(ensure!(if let &&0 = &&0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!($lit))` | = note: `!($lit) as i32` or `(!($lit)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:644:30 | 644 | let test = || Ok(ensure!(if let &mut 0 = &mut 0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!($lit))` | = note: `!($lit) as i32` or `(!($lit)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:650:30 | 650 | let test = || Ok(ensure!(if let &&mut 0 = &&mut 0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!($lit))` | = note: `!($lit) as i32` or `(!($lit)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:656:30 | 656 | let test = || Ok(ensure!(if let (0, 1) = (0, 1) { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let (0, 1) = (0, 1)))` | = note: `!(let (0, 1) = (0, 1)) as i32` or `(!(let (0, 1) = (0, 1))).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:662:30 | 662 | let test = || Ok(ensure!(if let [0] = b"\0" { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let [0] = b"\0"))` | = note: `!(let [0] = b"\0") as i32` or `(!(let [0] = b"\0")).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:669:30 | 669 | let test = || Ok(ensure!(if let P::<u8> {} = p { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!($ident))` | = note: `!($ident) as i32` or `(!($ident)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:681:30 | 681 | let test = || Ok(ensure!(if let <S as Trait>::V = 0 { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let <S as Trait>::V = 0))` | = note: `!(let <S as Trait>::V = 0) as i32` or `(!(let <S as Trait>::V = 0)).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if error: boolean to int conversion using if --> tests/test_ensure.rs:693:30 | 693 | let test = || Ok(ensure!(if let stringify!(x) = "x" { 0 } else { 1 } == 1)); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `i32::from(!(let stringify!(x) = "x"))` | = note: `!(let stringify!(x) = "x") as i32` or `(!(let stringify!(x) = "x")).into()` can also be valid options = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
- Loading branch information