[INFO] cloning repository https://github.com/INDA25PlusPlus/rsoderh-regex [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/INDA25PlusPlus/rsoderh-regex" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FINDA25PlusPlus%2Frsoderh-regex", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FINDA25PlusPlus%2Frsoderh-regex'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 7a95e67193969fc358a6babdb10e067565d602b1 [INFO] linting INDA25PlusPlus/rsoderh-regex against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FINDA25PlusPlus%2Frsoderh-regex" "/workspace/builds/worker-7-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-7-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/INDA25PlusPlus/rsoderh-regex [INFO] finished tweaking git repo https://github.com/INDA25PlusPlus/rsoderh-regex [INFO] tweaked toml for git repo https://github.com/INDA25PlusPlus/rsoderh-regex written to /workspace/builds/worker-7-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/INDA25PlusPlus/rsoderh-regex 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] crate git repo https://github.com/INDA25PlusPlus/rsoderh-regex already has a lockfile, it will not be regenerated [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] Blocking waiting for file lock on package cache [INFO] [stderr] Updating crates.io index [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded unicode-ident v1.0.23 [INFO] [stderr] Downloaded similar v2.7.0 [INFO] [stderr] Downloaded similar-asserts v1.7.0 [INFO] [stderr] Downloaded console v0.15.11 [INFO] [stderr] Downloaded encode_unicode v1.0.0 [INFO] [stderr] Downloaded anyhow v1.0.101 [INFO] [stderr] Downloaded arc-slice v0.1.0 [INFO] [stderr] Downloaded syn v2.0.115 [INFO] [stderr] Downloaded bstr v1.12.1 [INFO] [stderr] Downloaded libc v0.2.182 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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] 8613d06cd93e0bffc997a6c1ad363717be185b73088753a5ad9adbdb05d8c303 [INFO] running `Command { std: "docker" "start" "-a" "8613d06cd93e0bffc997a6c1ad363717be185b73088753a5ad9adbdb05d8c303", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "8613d06cd93e0bffc997a6c1ad363717be185b73088753a5ad9adbdb05d8c303", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "8613d06cd93e0bffc997a6c1ad363717be185b73088753a5ad9adbdb05d8c303", kill_on_drop: false }` [INFO] [stdout] 8613d06cd93e0bffc997a6c1ad363717be185b73088753a5ad9adbdb05d8c303 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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] 67936fa5616ce1585b30de69df61fecd662a134761a8aa606323bf27799601f7 [INFO] running `Command { std: "docker" "start" "-a" "67936fa5616ce1585b30de69df61fecd662a134761a8aa606323bf27799601f7", kill_on_drop: false }` [INFO] [stderr] Compiling libc v0.2.182 [INFO] [stderr] Compiling anyhow v1.0.101 [INFO] [stderr] Checking unicode-segmentation v1.12.0 [INFO] [stderr] Checking arc-slice v0.1.0 [INFO] [stderr] Checking similar v2.7.0 [INFO] [stderr] Checking template v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/parse.rs:43:13 [INFO] [stdout] | [INFO] [stdout] 43 | document: document, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: replace it with: `document` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] = note: `#[warn(clippy::redundant_field_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/parse.rs:452:13 [INFO] [stdout] | [INFO] [stdout] 452 | character: character, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: replace it with: `character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/automata/dfa.rs:83:9 [INFO] [stdout] | [INFO] [stdout] 83 | return String::from_utf8(out).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 83 - return String::from_utf8(out).unwrap(); [INFO] [stdout] 83 + String::from_utf8(out).unwrap() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/automata/mod.rs:51:65 [INFO] [stdout] | [INFO] [stdout] 51 | let result_states_nfa = inputs.entry(input).or_insert(BTreeSet::new()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `from_str` can be confused for the standard trait method `std::str::FromStr::from_str` [INFO] [stdout] --> src/parse.rs:48:5 [INFO] [stdout] | [INFO] [stdout] 48 | / pub fn from_str(string: &str) -> Self { [INFO] [stdout] 49 | | Self { [INFO] [stdout] 50 | | document: ArcSlice::from_slice(string), [INFO] [stdout] 51 | | pos: RefCell::new(0), [INFO] [stdout] 52 | | } [INFO] [stdout] 53 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: consider implementing the trait `std::str::FromStr` or choosing a less ambiguous method name [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait [INFO] [stdout] = note: `#[warn(clippy::should_implement_trait)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/parse.rs:79:48 [INFO] [stdout] | [INFO] [stdout] 79 | pub fn set_remaining_len(&self, len: usize) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/parse.rs:83:38 [INFO] [stdout] | [INFO] [stdout] 83 | pub fn consume(&self, len: usize) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/parse.rs:306:12 [INFO] [stdout] | [INFO] [stdout] 306 | if !parsed_document.strip_char('*').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('*').is_none()` [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/parse.rs:334:12 [INFO] [stdout] | [INFO] [stdout] 334 | if !parsed_document.strip_char('+').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('+').is_none()` [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/parse.rs:361:12 [INFO] [stdout] | [INFO] [stdout] 361 | if !parsed_document.strip_char('?').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('?').is_none()` [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: redundant pattern matching, consider using `is_some()` [INFO] [stdout] --> src/parse.rs:385:16 [INFO] [stdout] | [INFO] [stdout] 385 | if let Some(_) = parsed_document.strip_char('(') { [INFO] [stdout] | -------^^^^^^^---------------------------------- help: try: `if parsed_document.strip_char('(').is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/regex.rs:23:66 [INFO] [stdout] | [INFO] [stdout] 23 | let inputs = Utf8Iterator::new(&string[start..]).map(|chr| dfa::Input::Character(chr)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the tuple variant itself: `dfa::Input::Character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_some()` [INFO] [stdout] --> src/regex.rs:25:20 [INFO] [stdout] | [INFO] [stdout] 25 | if let Some(_) = self.dfa.execute(inputs, false) { [INFO] [stdout] | -------^^^^^^^---------------------------------- help: try: `if self.dfa.execute(inputs, false).is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/regex.rs:37:18 [INFO] [stdout] | [INFO] [stdout] 37 | .map(|chr| dfa::Input::Character(chr)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the tuple variant itself: `dfa::Input::Character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/regex.rs:36:40 [INFO] [stdout] | [INFO] [stdout] 36 | let inputs = Utf8Iterator::new(&string) [INFO] [stdout] | ^^^^^^^ help: change this to: `string` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/syntax.rs:103:8 [INFO] [stdout] | [INFO] [stdout] 103 | if document.rest().len() != 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!document.rest().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: returning the result of a `let` binding from a block [INFO] [stdout] --> src/utf8.rs:16:9 [INFO] [stdout] | [INFO] [stdout] 15 | let len = char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]); [INFO] [stdout] | --------------------------------------------------------------------------- unnecessary `let` binding [INFO] [stdout] 16 | len [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 15 ~ [INFO] [stdout] 16 ~ char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: calling `as_bytes` after slicing a string [INFO] [stdout] --> src/utf8.rs:15:44 [INFO] [stdout] | [INFO] [stdout] 15 | let len = char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&self.head.as_bytes()[self.offset..]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#sliced_string_as_bytes [INFO] [stdout] = note: `#[warn(clippy::sliced_string_as_bytes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/utf8.rs:44:12 [INFO] [stdout] | [INFO] [stdout] 44 | if self.head.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.head.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] [INFO] [stdout] [INFO] [stderr] Checking console v0.15.11 [INFO] [stderr] Checking similar-asserts v1.7.0 [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/parse.rs:43:13 [INFO] [stdout] | [INFO] [stdout] 43 | document: document, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: replace it with: `document` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] = note: `#[warn(clippy::redundant_field_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/parse.rs:452:13 [INFO] [stdout] | [INFO] [stdout] 452 | character: character, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: replace it with: `character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/automata/dfa.rs:83:9 [INFO] [stdout] | [INFO] [stdout] 83 | return String::from_utf8(out).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 83 - return String::from_utf8(out).unwrap(); [INFO] [stdout] 83 + String::from_utf8(out).unwrap() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/automata/mod.rs:51:65 [INFO] [stdout] | [INFO] [stdout] 51 | let result_states_nfa = inputs.entry(input).or_insert(BTreeSet::new()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `from_str` can be confused for the standard trait method `std::str::FromStr::from_str` [INFO] [stdout] --> src/parse.rs:48:5 [INFO] [stdout] | [INFO] [stdout] 48 | / pub fn from_str(string: &str) -> Self { [INFO] [stdout] 49 | | Self { [INFO] [stdout] 50 | | document: ArcSlice::from_slice(string), [INFO] [stdout] 51 | | pos: RefCell::new(0), [INFO] [stdout] 52 | | } [INFO] [stdout] 53 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: consider implementing the trait `std::str::FromStr` or choosing a less ambiguous method name [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait [INFO] [stdout] = note: `#[warn(clippy::should_implement_trait)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/parse.rs:79:48 [INFO] [stdout] | [INFO] [stdout] 79 | pub fn set_remaining_len(&self, len: usize) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/parse.rs:83:38 [INFO] [stdout] | [INFO] [stdout] 83 | pub fn consume(&self, len: usize) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/parse.rs:306:12 [INFO] [stdout] | [INFO] [stdout] 306 | if !parsed_document.strip_char('*').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('*').is_none()` [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/parse.rs:334:12 [INFO] [stdout] | [INFO] [stdout] 334 | if !parsed_document.strip_char('+').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('+').is_none()` [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/parse.rs:361:12 [INFO] [stdout] | [INFO] [stdout] 361 | if !parsed_document.strip_char('?').is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `parsed_document.strip_char('?').is_none()` [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: redundant pattern matching, consider using `is_some()` [INFO] [stdout] --> src/parse.rs:385:16 [INFO] [stdout] | [INFO] [stdout] 385 | if let Some(_) = parsed_document.strip_char('(') { [INFO] [stdout] | -------^^^^^^^---------------------------------- help: try: `if parsed_document.strip_char('(').is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/regex.rs:23:66 [INFO] [stdout] | [INFO] [stdout] 23 | let inputs = Utf8Iterator::new(&string[start..]).map(|chr| dfa::Input::Character(chr)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the tuple variant itself: `dfa::Input::Character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_some()` [INFO] [stdout] --> src/regex.rs:25:20 [INFO] [stdout] | [INFO] [stdout] 25 | if let Some(_) = self.dfa.execute(inputs, false) { [INFO] [stdout] | -------^^^^^^^---------------------------------- help: try: `if self.dfa.execute(inputs, false).is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/regex.rs:37:18 [INFO] [stdout] | [INFO] [stdout] 37 | .map(|chr| dfa::Input::Character(chr)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the tuple variant itself: `dfa::Input::Character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/regex.rs:36:40 [INFO] [stdout] | [INFO] [stdout] 36 | let inputs = Utf8Iterator::new(&string) [INFO] [stdout] | ^^^^^^^ help: change this to: `string` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:62:9 [INFO] [stdout] | [INFO] [stdout] 62 | assert_eq!(regex.matches_all("abababab"), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_assert_comparison)]` on by default [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 62 - assert_eq!(regex.matches_all("abababab"), true); [INFO] [stdout] 62 + assert!(regex.matches_all("abababab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:63:9 [INFO] [stdout] | [INFO] [stdout] 63 | assert_eq!(regex.matches_all(""), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 63 - assert_eq!(regex.matches_all(""), true); [INFO] [stdout] 63 + assert!(regex.matches_all("")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:64:9 [INFO] [stdout] | [INFO] [stdout] 64 | assert_eq!(regex.matches_all("cd"), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 64 - assert_eq!(regex.matches_all("cd"), true); [INFO] [stdout] 64 + assert!(regex.matches_all("cd")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:65:9 [INFO] [stdout] | [INFO] [stdout] 65 | assert_eq!(regex.matches_all("c"), false); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 65 - assert_eq!(regex.matches_all("c"), false); [INFO] [stdout] 65 + assert!(!regex.matches_all("c")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:80:9 [INFO] [stdout] | [INFO] [stdout] 80 | assert_eq!(regex.matches_all("ab"), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 80 - assert_eq!(regex.matches_all("ab"), true); [INFO] [stdout] 80 + assert!(regex.matches_all("ab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:81:9 [INFO] [stdout] | [INFO] [stdout] 81 | assert_eq!(regex.matches_all(""), false); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 81 - assert_eq!(regex.matches_all(""), false); [INFO] [stdout] 81 + assert!(!regex.matches_all("")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:88:9 [INFO] [stdout] | [INFO] [stdout] 88 | assert_eq!(regex.matches_all("ab"), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 88 - assert_eq!(regex.matches_all("ab"), true); [INFO] [stdout] 88 + assert!(regex.matches_all("ab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:89:9 [INFO] [stdout] | [INFO] [stdout] 89 | assert_eq!(regex.matches_all(""), true); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 89 - assert_eq!(regex.matches_all(""), true); [INFO] [stdout] 89 + assert!(regex.matches_all("")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/regex.rs:90:9 [INFO] [stdout] | [INFO] [stdout] 90 | assert_eq!(regex.matches_all("something else"), false); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 90 - assert_eq!(regex.matches_all("something else"), false); [INFO] [stdout] 90 + assert!(!regex.matches_all("something else")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/syntax.rs:103:8 [INFO] [stdout] | [INFO] [stdout] 103 | if document.rest().len() != 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!document.rest().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: returning the result of a `let` binding from a block [INFO] [stdout] --> src/utf8.rs:16:9 [INFO] [stdout] | [INFO] [stdout] 15 | let len = char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]); [INFO] [stdout] | --------------------------------------------------------------------------- unnecessary `let` binding [INFO] [stdout] 16 | len [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 15 ~ [INFO] [stdout] 16 ~ char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: calling `as_bytes` after slicing a string [INFO] [stdout] --> src/utf8.rs:15:44 [INFO] [stdout] | [INFO] [stdout] 15 | let len = char_len_from_first_byte(self.head[self.offset..].as_bytes()[0]); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&self.head.as_bytes()[self.offset..]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#sliced_string_as_bytes [INFO] [stdout] = note: `#[warn(clippy::sliced_string_as_bytes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/utf8.rs:44:12 [INFO] [stdout] | [INFO] [stdout] 44 | if self.head.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.head.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] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 4.01s [INFO] running `Command { std: "docker" "inspect" "67936fa5616ce1585b30de69df61fecd662a134761a8aa606323bf27799601f7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "67936fa5616ce1585b30de69df61fecd662a134761a8aa606323bf27799601f7", kill_on_drop: false }` [INFO] [stdout] 67936fa5616ce1585b30de69df61fecd662a134761a8aa606323bf27799601f7