[INFO] fetching crate rcstring 0.2.1... [INFO] linting rcstring-0.2.1 against nightly for clippy-nonminimal_bool-denied [INFO] extracting crate rcstring 0.2.1 into /workspace/builds/worker-5-tc1/source [INFO] started tweaking crates.io crate rcstring 0.2.1 [INFO] finished tweaking crates.io crate rcstring 0.2.1 [INFO] tweaked toml for crates.io crate rcstring 0.2.1 written to /workspace/builds/worker-5-tc1/source/Cargo.toml [INFO] validating manifest of crates.io crate rcstring 0.2.1 on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "generate-lockfile" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] warning: `package.edition` is unspecified, defaulting to `2015` while the latest is `2024` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] d374691a6fda8da7d9c2aace55c391f2f42fc88f7a24129446e44acf2335c462 [INFO] running `Command { std: "docker" "start" "-a" "d374691a6fda8da7d9c2aace55c391f2f42fc88f7a24129446e44acf2335c462", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "d374691a6fda8da7d9c2aace55c391f2f42fc88f7a24129446e44acf2335c462", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "d374691a6fda8da7d9c2aace55c391f2f42fc88f7a24129446e44acf2335c462", kill_on_drop: false }` [INFO] [stdout] d374691a6fda8da7d9c2aace55c391f2f42fc88f7a24129446e44acf2335c462 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] fad22570e5d49376f44656776dfad325673ab56bce37420a31bf00803a026bf8 [INFO] running `Command { std: "docker" "start" "-a" "fad22570e5d49376f44656776dfad325673ab56bce37420a31bf00803a026bf8", kill_on_drop: false }` [INFO] [stderr] warning: `package.edition` is unspecified, defaulting to `2015` while the latest is `2024` [INFO] [stderr] Checking rcstring v0.2.1 (/opt/rustwide/workdir) [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/lib.rs:67:18 [INFO] [stdout] | [INFO] [stdout] 67 | pub struct Error(&'static str); [INFO] [stdout] | ----- ^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Error` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `offset` with a `usize` casted to an `isize` [INFO] [stdout] --> src/lib.rs:85:22 [INFO] [stdout] | [INFO] [stdout] 85 | if unsafe { *ptr.offset(ctr as isize) < 0 as c_char } { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_offset_with_cast [INFO] [stdout] = note: `#[warn(clippy::ptr_offset_with_cast)]` on by default [INFO] [stdout] help: use `add` instead [INFO] [stdout] | [INFO] [stdout] 85 - if unsafe { *ptr.offset(ctr as isize) < 0 as c_char } { [INFO] [stdout] 85 + if unsafe { *ptr.add(ctr) < 0 as c_char } { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/lib.rs:112:12 [INFO] [stdout] | [INFO] [stdout] 112 | if s.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `s.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unsafe function's docs are missing a `# Safety` section [INFO] [stdout] --> src/lib.rs:136:5 [INFO] [stdout] | [INFO] [stdout] 136 | pub unsafe fn from_raw(ptr: *const c_char) -> Result, Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc [INFO] [stdout] = note: `#[warn(clippy::missing_safety_doc)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unsafe function's docs are missing a `# Safety` section [INFO] [stdout] --> src/lib.rs:154:5 [INFO] [stdout] | [INFO] [stdout] 154 | pub unsafe fn into_raw(&self) -> *const c_char { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `CString` has a public `len` method, but no `is_empty` method [INFO] [stdout] --> src/lib.rs:159:5 [INFO] [stdout] | [INFO] [stdout] 159 | pub fn len(&self) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_without_is_empty [INFO] [stdout] = note: `#[warn(clippy::len_without_is_empty)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: re-implementing `PartialEq::ne` is unnecessary [INFO] [stdout] --> src/lib.rs:173:5 [INFO] [stdout] | [INFO] [stdout] 173 | fn ne(&self, other: &CString) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_ne_impl [INFO] [stdout] = note: `#[warn(clippy::partialeq_ne_impl)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/lib.rs:67:18 [INFO] [stdout] | [INFO] [stdout] 67 | pub struct Error(&'static str); [INFO] [stdout] | ----- ^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Error` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `offset` with a `usize` casted to an `isize` [INFO] [stdout] --> src/lib.rs:85:22 [INFO] [stdout] | [INFO] [stdout] 85 | if unsafe { *ptr.offset(ctr as isize) < 0 as c_char } { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_offset_with_cast [INFO] [stdout] = note: `#[warn(clippy::ptr_offset_with_cast)]` on by default [INFO] [stdout] help: use `add` instead [INFO] [stdout] | [INFO] [stdout] 85 - if unsafe { *ptr.offset(ctr as isize) < 0 as c_char } { [INFO] [stdout] 85 + if unsafe { *ptr.add(ctr) < 0 as c_char } { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-canonical implementation of `partial_cmp` on an `Ord` type [INFO] [stdout] --> src/lib.rs:178:1 [INFO] [stdout] | [INFO] [stdout] 178 | / impl<'a> PartialOrd for CString<'a> { [INFO] [stdout] 179 | | fn partial_cmp(&self, other: &CString) -> Option { [INFO] [stdout] 180 | | unsafe { [INFO] [stdout] 181 | | slice::from_raw_parts(self.data, self.len()) [INFO] [stdout] ... | [INFO] [stdout] 215 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#non_canonical_partial_ord_impl [INFO] [stdout] = note: `#[warn(clippy::non_canonical_partial_ord_impl)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 179 - fn partial_cmp(&self, other: &CString) -> Option { [INFO] [stdout] 180 - unsafe { [INFO] [stdout] 181 - slice::from_raw_parts(self.data, self.len()) [INFO] [stdout] 182 - .partial_cmp(slice::from_raw_parts(other.data, other.len())) [INFO] [stdout] 183 - } [INFO] [stdout] 184 - } [INFO] [stdout] 179 + fn partial_cmp(&self, other: &CString) -> Option { Some(self.cmp(other)) } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/lib.rs:112:12 [INFO] [stdout] | [INFO] [stdout] 112 | if s.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `s.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:187:9 [INFO] [stdout] | [INFO] [stdout] 187 | / match self.partial_cmp(other) { [INFO] [stdout] 188 | | Some(Less) => true, [INFO] [stdout] 189 | | Some(Equal) => true, [INFO] [stdout] 190 | | _ => false [INFO] [stdout] 191 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 187 - match self.partial_cmp(other) { [INFO] [stdout] 188 - Some(Less) => true, [INFO] [stdout] 189 - Some(Equal) => true, [INFO] [stdout] 190 - _ => false [INFO] [stdout] 191 - } [INFO] [stdout] 187 + matches!(self.partial_cmp(other), Some(Less) | Some(Equal)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:195:9 [INFO] [stdout] | [INFO] [stdout] 195 | / match self.partial_cmp(other) { [INFO] [stdout] 196 | | Some(Greater) => true, [INFO] [stdout] 197 | | Some(Equal) => true, [INFO] [stdout] 198 | | _ => false [INFO] [stdout] 199 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 195 - match self.partial_cmp(other) { [INFO] [stdout] 196 - Some(Greater) => true, [INFO] [stdout] 197 - Some(Equal) => true, [INFO] [stdout] 198 - _ => false [INFO] [stdout] 199 - } [INFO] [stdout] 195 + matches!(self.partial_cmp(other), Some(Greater) | Some(Equal)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:203:9 [INFO] [stdout] | [INFO] [stdout] 203 | / match self.partial_cmp(other) { [INFO] [stdout] 204 | | Some(Less) => true, [INFO] [stdout] 205 | | _ => false [INFO] [stdout] 206 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 203 - match self.partial_cmp(other) { [INFO] [stdout] 204 - Some(Less) => true, [INFO] [stdout] 205 - _ => false [INFO] [stdout] 206 - } [INFO] [stdout] 203 + matches!(self.partial_cmp(other), Some(Less)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:210:9 [INFO] [stdout] | [INFO] [stdout] 210 | / match self.partial_cmp(other) { [INFO] [stdout] 211 | | Some(Greater) => true, [INFO] [stdout] 212 | | _ => false [INFO] [stdout] 213 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 210 - match self.partial_cmp(other) { [INFO] [stdout] 211 - Some(Greater) => true, [INFO] [stdout] 212 - _ => false [INFO] [stdout] 213 - } [INFO] [stdout] 210 + matches!(self.partial_cmp(other), Some(Greater)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/lib.rs:256:21 [INFO] [stdout] | [INFO] [stdout] 256 | assert!(! cstr_res.is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `cstr_res.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/lib.rs:261:21 [INFO] [stdout] | [INFO] [stdout] 261 | assert!(! cstr_res.is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `cstr_res.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/lib.rs:266:21 [INFO] [stdout] | [INFO] [stdout] 266 | assert!(! cstr_res.is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `cstr_res.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/lib.rs:271:21 [INFO] [stdout] | [INFO] [stdout] 271 | assert!(! cstr_res.is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `cstr_res.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unsafe function's docs are missing a `# Safety` section [INFO] [stdout] --> src/lib.rs:136:5 [INFO] [stdout] | [INFO] [stdout] 136 | pub unsafe fn from_raw(ptr: *const c_char) -> Result, Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc [INFO] [stdout] = note: `#[warn(clippy::missing_safety_doc)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unsafe function's docs are missing a `# Safety` section [INFO] [stdout] --> src/lib.rs:154:5 [INFO] [stdout] | [INFO] [stdout] 154 | pub unsafe fn into_raw(&self) -> *const c_char { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `CString` has a public `len` method, but no `is_empty` method [INFO] [stdout] --> src/lib.rs:159:5 [INFO] [stdout] | [INFO] [stdout] 159 | pub fn len(&self) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_without_is_empty [INFO] [stdout] = note: `#[warn(clippy::len_without_is_empty)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: re-implementing `PartialEq::ne` is unnecessary [INFO] [stdout] --> src/lib.rs:173:5 [INFO] [stdout] | [INFO] [stdout] 173 | fn ne(&self, other: &CString) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_ne_impl [INFO] [stdout] = note: `#[warn(clippy::partialeq_ne_impl)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-canonical implementation of `partial_cmp` on an `Ord` type [INFO] [stdout] --> src/lib.rs:178:1 [INFO] [stdout] | [INFO] [stdout] 178 | / impl<'a> PartialOrd for CString<'a> { [INFO] [stdout] 179 | | fn partial_cmp(&self, other: &CString) -> Option { [INFO] [stdout] 180 | | unsafe { [INFO] [stdout] 181 | | slice::from_raw_parts(self.data, self.len()) [INFO] [stdout] ... | [INFO] [stdout] 215 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#non_canonical_partial_ord_impl [INFO] [stdout] = note: `#[warn(clippy::non_canonical_partial_ord_impl)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 179 - fn partial_cmp(&self, other: &CString) -> Option { [INFO] [stdout] 180 - unsafe { [INFO] [stdout] 181 - slice::from_raw_parts(self.data, self.len()) [INFO] [stdout] 182 - .partial_cmp(slice::from_raw_parts(other.data, other.len())) [INFO] [stdout] 183 - } [INFO] [stdout] 184 - } [INFO] [stdout] 179 + fn partial_cmp(&self, other: &CString) -> Option { Some(self.cmp(other)) } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:187:9 [INFO] [stdout] | [INFO] [stdout] 187 | / match self.partial_cmp(other) { [INFO] [stdout] 188 | | Some(Less) => true, [INFO] [stdout] 189 | | Some(Equal) => true, [INFO] [stdout] 190 | | _ => false [INFO] [stdout] 191 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 187 - match self.partial_cmp(other) { [INFO] [stdout] 188 - Some(Less) => true, [INFO] [stdout] 189 - Some(Equal) => true, [INFO] [stdout] 190 - _ => false [INFO] [stdout] 191 - } [INFO] [stdout] 187 + matches!(self.partial_cmp(other), Some(Less) | Some(Equal)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:195:9 [INFO] [stdout] | [INFO] [stdout] 195 | / match self.partial_cmp(other) { [INFO] [stdout] 196 | | Some(Greater) => true, [INFO] [stdout] 197 | | Some(Equal) => true, [INFO] [stdout] 198 | | _ => false [INFO] [stdout] 199 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 195 - match self.partial_cmp(other) { [INFO] [stdout] 196 - Some(Greater) => true, [INFO] [stdout] 197 - Some(Equal) => true, [INFO] [stdout] 198 - _ => false [INFO] [stdout] 199 - } [INFO] [stdout] 195 + matches!(self.partial_cmp(other), Some(Greater) | Some(Equal)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:203:9 [INFO] [stdout] | [INFO] [stdout] 203 | / match self.partial_cmp(other) { [INFO] [stdout] 204 | | Some(Less) => true, [INFO] [stdout] 205 | | _ => false [INFO] [stdout] 206 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 203 - match self.partial_cmp(other) { [INFO] [stdout] 204 - Some(Less) => true, [INFO] [stdout] 205 - _ => false [INFO] [stdout] 206 - } [INFO] [stdout] 203 + matches!(self.partial_cmp(other), Some(Less)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/lib.rs:210:9 [INFO] [stdout] | [INFO] [stdout] 210 | / match self.partial_cmp(other) { [INFO] [stdout] 211 | | Some(Greater) => true, [INFO] [stdout] 212 | | _ => false [INFO] [stdout] 213 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 210 - match self.partial_cmp(other) { [INFO] [stdout] 211 - Some(Greater) => true, [INFO] [stdout] 212 - _ => false [INFO] [stdout] 213 - } [INFO] [stdout] 210 + matches!(self.partial_cmp(other), Some(Greater)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.14s [INFO] running `Command { std: "docker" "inspect" "fad22570e5d49376f44656776dfad325673ab56bce37420a31bf00803a026bf8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "fad22570e5d49376f44656776dfad325673ab56bce37420a31bf00803a026bf8", kill_on_drop: false }` [INFO] [stdout] fad22570e5d49376f44656776dfad325673ab56bce37420a31bf00803a026bf8