[INFO] cloning repository https://github.com/hansihe/rust_iterative_json_parser [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/hansihe/rust_iterative_json_parser" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhansihe%2Frust_iterative_json_parser", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhansihe%2Frust_iterative_json_parser'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 3f0ffa48024c44cdc26d65118cdc1114ca8900bd [INFO] linting hansihe/rust_iterative_json_parser against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhansihe%2Frust_iterative_json_parser" "/workspace/builds/worker-5-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-5-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/hansihe/rust_iterative_json_parser [INFO] finished tweaking git repo https://github.com/hansihe/rust_iterative_json_parser [INFO] tweaked toml for git repo https://github.com/hansihe/rust_iterative_json_parser written to /workspace/builds/worker-5-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/hansihe/rust_iterative_json_parser 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/hansihe/rust_iterative_json_parser 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] warning: `package.edition` is unspecified, defaulting to `2015` while the latest is `2024` [INFO] [stderr] warning: unused manifest key: lib.src [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 simd v0.2.0 [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] c605894c7e0c3a4fd3c2dc2a1370e66eb3307cce558640d4c080ced917167b85 [INFO] running `Command { std: "docker" "start" "-a" "c605894c7e0c3a4fd3c2dc2a1370e66eb3307cce558640d4c080ced917167b85", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "c605894c7e0c3a4fd3c2dc2a1370e66eb3307cce558640d4c080ced917167b85", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "c605894c7e0c3a4fd3c2dc2a1370e66eb3307cce558640d4c080ced917167b85", kill_on_drop: false }` [INFO] [stdout] c605894c7e0c3a4fd3c2dc2a1370e66eb3307cce558640d4c080ced917167b85 [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] 35dff47ad38a328a82202c429bc46b1d770ba098fd5113708b2d485972ad83fa [INFO] running `Command { std: "docker" "start" "-a" "35dff47ad38a328a82202c429bc46b1d770ba098fd5113708b2d485972ad83fa", kill_on_drop: false }` [INFO] [stderr] warning: `package.edition` is unspecified, defaulting to `2015` while the latest is `2024` [INFO] [stderr] warning: unused manifest key: lib.src [INFO] [stderr] Checking iterative_json_parser v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused macro definition: `lift_bail` [INFO] [stdout] --> src/parser.rs:110:14 [INFO] [stdout] | [INFO] [stdout] 110 | macro_rules! lift_bail { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_macros)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:272:29 [INFO] [stdout] | [INFO] [stdout] 272 | b'A'...b'F' => *codepoint |= (byte - b'A' + 10) as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] = note: `#[warn(ellipsis_inclusive_range_patterns)]` (part of `#[warn(rust_2021_compatibility)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:273:29 [INFO] [stdout] | [INFO] [stdout] 273 | b'a'...b'f' => *codepoint |= (byte - b'a' + 10) as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:274:29 [INFO] [stdout] | [INFO] [stdout] 274 | b'0'...b'9' => *codepoint |= (byte - b'0') as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:319:36 [INFO] [stdout] | [INFO] [stdout] 319 | PeekResult::Ok(b'0'...b'9') => ss.skip(1), [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:368:29 [INFO] [stdout] | [INFO] [stdout] 368 | b'0'...b'9' => { [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/sink/into_enum.rs:33:13 [INFO] [stdout] | [INFO] [stdout] 33 | source: source, [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace it with: `source` [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: unused macro definition: `lift_bail` [INFO] [stdout] --> src/parser.rs:110:14 [INFO] [stdout] | [INFO] [stdout] 110 | macro_rules! lift_bail { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_macros)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `::PResult` [INFO] [stdout] --> src/source/mod.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use ::PResult; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/source/string.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | vec: vec, [INFO] [stdout] | ^^^^^^^^ help: replace it with: `vec` [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: redundant field names in struct initialization [INFO] [stdout] --> src/source/string.rs:63:13 [INFO] [stdout] | [INFO] [stdout] 63 | vec: vec, [INFO] [stdout] | ^^^^^^^^ help: replace it with: `vec` [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: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:272:29 [INFO] [stdout] | [INFO] [stdout] 272 | b'A'...b'F' => *codepoint |= (byte - b'A' + 10) as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] = note: `#[warn(ellipsis_inclusive_range_patterns)]` (part of `#[warn(rust_2021_compatibility)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:273:29 [INFO] [stdout] | [INFO] [stdout] 273 | b'a'...b'f' => *codepoint |= (byte - b'a' + 10) as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:274:29 [INFO] [stdout] | [INFO] [stdout] 274 | b'0'...b'9' => *codepoint |= (byte - b'0') as u32, [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:319:36 [INFO] [stdout] | [INFO] [stdout] 319 | PeekResult::Ok(b'0'...b'9') => ss.skip(1), [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `...` range patterns are deprecated [INFO] [stdout] --> src/tokenizer.rs:368:29 [INFO] [stdout] | [INFO] [stdout] 368 | b'0'...b'9' => { [INFO] [stdout] | ^^^ help: use `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021! [INFO] [stdout] = note: for more information, see [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/sink/into_enum.rs:33:13 [INFO] [stdout] | [INFO] [stdout] 33 | source: source, [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace it with: `source` [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: unused import: `::PResult` [INFO] [stdout] --> src/source/mod.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use ::PResult; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/source/string.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | vec: vec, [INFO] [stdout] | ^^^^^^^^ help: replace it with: `vec` [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: redundant field names in struct initialization [INFO] [stdout] --> src/source/string.rs:63:13 [INFO] [stdout] | [INFO] [stdout] 63 | vec: vec, [INFO] [stdout] | ^^^^^^^^ help: replace it with: `vec` [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: unused variable: `token` [INFO] [stdout] --> src/parser.rs:136:14 [INFO] [stdout] | [INFO] [stdout] 136 | fn log_token(token: &str) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_token` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `token` [INFO] [stdout] --> src/parser.rs:136:14 [INFO] [stdout] | [INFO] [stdout] 136 | fn log_token(token: &str) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_token` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Decoder` is never constructed [INFO] [stdout] --> src/decoder.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | struct Decoder { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/decoder.rs:10:8 [INFO] [stdout] | [INFO] [stdout] 9 | impl Decoder { [INFO] [stdout] | ------------ associated function in this implementation [INFO] [stdout] 10 | fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ParserState` [INFO] [stdout] --> src/parser.rs:143:5 [INFO] [stdout] | [INFO] [stdout] 143 | / pub fn new() -> Self { [INFO] [stdout] 144 | | ParserState { [INFO] [stdout] 145 | | stack: vec![], [INFO] [stdout] ... | [INFO] [stdout] 155 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 141 + impl Default for ParserState { [INFO] [stdout] 142 + fn default() -> Self { [INFO] [stdout] 143 + Self::new() [INFO] [stdout] 144 + } [INFO] [stdout] 145 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:272:12 [INFO] [stdout] | [INFO] [stdout] 272 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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: length comparison to zero [INFO] [stdout] --> src/parser.rs:317:12 [INFO] [stdout] | [INFO] [stdout] 317 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:490:12 [INFO] [stdout] | [INFO] [stdout] 490 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:506:12 [INFO] [stdout] | [INFO] [stdout] 506 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: struct `Decoder` is never constructed [INFO] [stdout] --> src/decoder.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | struct Decoder { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/decoder.rs:10:8 [INFO] [stdout] | [INFO] [stdout] 9 | impl Decoder { [INFO] [stdout] | ------------ associated function in this implementation [INFO] [stdout] 10 | fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:585:41 [INFO] [stdout] | [INFO] [stdout] 585 | self.state == TopState::None && self.stack.len() == 0 && !self.read_value && self.started [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: you should consider adding a `Default` implementation for `TokenizerState` [INFO] [stdout] --> src/tokenizer.rs:50:5 [INFO] [stdout] | [INFO] [stdout] 50 | / pub fn new() -> TokenizerState { [INFO] [stdout] 51 | | TokenizerState { [INFO] [stdout] 52 | | state: TokenState::None, [INFO] [stdout] 53 | | parser: ParserState::new(), [INFO] [stdout] ... | [INFO] [stdout] 60 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 49 + impl Default for TokenizerState { [INFO] [stdout] 50 + fn default() -> Self { [INFO] [stdout] 51 + Self::new() [INFO] [stdout] 52 + } [INFO] [stdout] 53 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/tokenizer.rs:93:39 [INFO] [stdout] | [INFO] [stdout] 93 | PeekResult::Bail(bail) => return Err(ParseError::SourceBail(bail)), [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] 93 - PeekResult::Bail(bail) => return Err(ParseError::SourceBail(bail)), [INFO] [stdout] 93 + PeekResult::Bail(bail) => Err(ParseError::SourceBail(bail)), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/tokenizer.rs:94:32 [INFO] [stdout] | [INFO] [stdout] 94 | PeekResult::Eof => return Err(ParseError::Eof), [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 94 - PeekResult::Eof => return Err(ParseError::Eof), [INFO] [stdout] 94 + PeekResult::Eof => Err(ParseError::Eof), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ParserState` [INFO] [stdout] --> src/parser.rs:143:5 [INFO] [stdout] | [INFO] [stdout] 143 | / pub fn new() -> Self { [INFO] [stdout] 144 | | ParserState { [INFO] [stdout] 145 | | stack: vec![], [INFO] [stdout] ... | [INFO] [stdout] 155 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 141 + impl Default for ParserState { [INFO] [stdout] 142 + fn default() -> Self { [INFO] [stdout] 143 + Self::new() [INFO] [stdout] 144 + } [INFO] [stdout] 145 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/tokenizer.rs:164:32 [INFO] [stdout] | [INFO] [stdout] 164 | ... if !(range.start == range.end) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(range.start != range.end)` [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/tokenizer.rs:177:32 [INFO] [stdout] | [INFO] [stdout] 177 | ... if !(range.start == range.end) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(range.start != range.end)` [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: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> src/tokenizer.rs:230:24 [INFO] [stdout] | [INFO] [stdout] 230 | if codepoint >= 0xd800 && codepoint <= 0xdbff { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(0xd800..=0xdbff).contains(&codepoint)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] = note: `#[warn(clippy::manual_range_contains)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> src/tokenizer.rs:248:24 [INFO] [stdout] | [INFO] [stdout] 248 | if lower >= 0xdc00 && lower <= 0xdfff { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(0xdc00..=0xdfff).contains(&lower)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u8` -> `u8`) [INFO] [stdout] --> src/tokenizer.rs:270:32 [INFO] [stdout] | [INFO] [stdout] 270 | let byte = character as u8; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:272:12 [INFO] [stdout] | [INFO] [stdout] 272 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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: length comparison to zero [INFO] [stdout] --> src/parser.rs:317:12 [INFO] [stdout] | [INFO] [stdout] 317 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: you should consider adding a `Default` implementation for `PrintSink` [INFO] [stdout] --> src/sink/debug_print.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | / pub fn new() -> PrintSink { [INFO] [stdout] 9 | | PrintSink {} [INFO] [stdout] 10 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 7 + impl Default for PrintSink { [INFO] [stdout] 8 + fn default() -> Self { [INFO] [stdout] 9 + Self::new() [INFO] [stdout] 10 + } [INFO] [stdout] 11 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:490:12 [INFO] [stdout] | [INFO] [stdout] 490 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:506:12 [INFO] [stdout] | [INFO] [stdout] 506 | if self.stack.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: the following explicit lifetimes could be elided: 'b [INFO] [stdout] --> src/sink/into_enum.rs:44:21 [INFO] [stdout] | [INFO] [stdout] 44 | fn range_to_str<'b>(&'b mut self, range: Range) -> &'b str { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] = note: `#[warn(clippy::needless_lifetimes)]` on by default [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 44 - fn range_to_str<'b>(&'b mut self, range: Range) -> &'b str { [INFO] [stdout] 44 + fn range_to_str(&mut self, range: Range) -> &str { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/parser.rs:585:41 [INFO] [stdout] | [INFO] [stdout] 585 | self.state == TopState::None && self.stack.len() == 0 && !self.read_value && self.started [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.stack.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] [stdout] warning: you should consider adding a `Default` implementation for `TokenizerState` [INFO] [stdout] --> src/tokenizer.rs:50:5 [INFO] [stdout] | [INFO] [stdout] 50 | / pub fn new() -> TokenizerState { [INFO] [stdout] 51 | | TokenizerState { [INFO] [stdout] 52 | | state: TokenState::None, [INFO] [stdout] 53 | | parser: ParserState::new(), [INFO] [stdout] ... | [INFO] [stdout] 60 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 49 + impl Default for TokenizerState { [INFO] [stdout] 50 + fn default() -> Self { [INFO] [stdout] 51 + Self::new() [INFO] [stdout] 52 + } [INFO] [stdout] 53 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/tokenizer.rs:93:39 [INFO] [stdout] | [INFO] [stdout] 93 | PeekResult::Bail(bail) => return Err(ParseError::SourceBail(bail)), [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] 93 - PeekResult::Bail(bail) => return Err(ParseError::SourceBail(bail)), [INFO] [stdout] 93 + PeekResult::Bail(bail) => Err(ParseError::SourceBail(bail)), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/tokenizer.rs:94:32 [INFO] [stdout] | [INFO] [stdout] 94 | PeekResult::Eof => return Err(ParseError::Eof), [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 94 - PeekResult::Eof => return Err(ParseError::Eof), [INFO] [stdout] 94 + PeekResult::Eof => Err(ParseError::Eof), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/tokenizer.rs:164:32 [INFO] [stdout] | [INFO] [stdout] 164 | ... if !(range.start == range.end) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(range.start != range.end)` [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/tokenizer.rs:177:32 [INFO] [stdout] | [INFO] [stdout] 177 | ... if !(range.start == range.end) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(range.start != range.end)` [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: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> src/tokenizer.rs:230:24 [INFO] [stdout] | [INFO] [stdout] 230 | if codepoint >= 0xd800 && codepoint <= 0xdbff { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(0xd800..=0xdbff).contains(&codepoint)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] = note: `#[warn(clippy::manual_range_contains)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> src/tokenizer.rs:248:24 [INFO] [stdout] | [INFO] [stdout] 248 | if lower >= 0xdc00 && lower <= 0xdfff { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(0xdc00..=0xdfff).contains(&lower)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u8` -> `u8`) [INFO] [stdout] --> src/tokenizer.rs:270:32 [INFO] [stdout] | [INFO] [stdout] 270 | let byte = character as u8; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `character` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/input.rs:85:19 [INFO] [stdout] | [INFO] [stdout] 85 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 85 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 85 + fn peek_slice(&self, length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `PrintSink` [INFO] [stdout] --> src/sink/debug_print.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | / pub fn new() -> PrintSink { [INFO] [stdout] 9 | | PrintSink {} [INFO] [stdout] 10 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 7 + impl Default for PrintSink { [INFO] [stdout] 8 + fn default() -> Self { [INFO] [stdout] 9 + Self::new() [INFO] [stdout] 10 + } [INFO] [stdout] 11 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/string.rs:45:19 [INFO] [stdout] | [INFO] [stdout] 45 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 45 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 45 + fn peek_slice(&self, length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/string.rs:101:19 [INFO] [stdout] | [INFO] [stdout] 101 | fn peek_slice<'a>(&'a self, _length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 101 - fn peek_slice<'a>(&'a self, _length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 101 + fn peek_slice(&self, _length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/mod.rs:17:19 [INFO] [stdout] | [INFO] [stdout] 17 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]>; [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 17 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]>; [INFO] [stdout] 17 + fn peek_slice(&self, length: usize) -> Option<&[u8]>; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'b [INFO] [stdout] --> src/sink/into_enum.rs:44:21 [INFO] [stdout] | [INFO] [stdout] 44 | fn range_to_str<'b>(&'b mut self, range: Range) -> &'b str { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] = note: `#[warn(clippy::needless_lifetimes)]` on by default [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 44 - fn range_to_str<'b>(&'b mut self, range: Range) -> &'b str { [INFO] [stdout] 44 + fn range_to_str(&mut self, range: Range) -> &str { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/sink/into_enum.rs:30:37 [INFO] [stdout] | [INFO] [stdout] 30 | pub fn new(source: &'a [u8]) -> EnumSink { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 30 | pub fn new(source: &'a [u8]) -> EnumSink<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/sink/into_enum.rs:38:45 [INFO] [stdout] | [INFO] [stdout] 38 | pub fn new_bailing(source: &'a [u8]) -> EnumSink { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 38 | pub fn new_bailing(source: &'a [u8]) -> EnumSink<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/input.rs:85:19 [INFO] [stdout] | [INFO] [stdout] 85 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 85 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 85 + fn peek_slice(&self, length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/string.rs:45:19 [INFO] [stdout] | [INFO] [stdout] 45 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 45 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 45 + fn peek_slice(&self, length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/string.rs:101:19 [INFO] [stdout] | [INFO] [stdout] 101 | fn peek_slice<'a>(&'a self, _length: usize) -> Option<&'a [u8]> { [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 101 - fn peek_slice<'a>(&'a self, _length: usize) -> Option<&'a [u8]> { [INFO] [stdout] 101 + fn peek_slice(&self, _length: usize) -> Option<&[u8]> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the following explicit lifetimes could be elided: 'a [INFO] [stdout] --> src/source/mod.rs:17:19 [INFO] [stdout] | [INFO] [stdout] 17 | fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]>; [INFO] [stdout] | ^^ ^^ ^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stdout] help: elide the lifetimes [INFO] [stdout] | [INFO] [stdout] 17 - fn peek_slice<'a>(&'a self, length: usize) -> Option<&'a [u8]>; [INFO] [stdout] 17 + fn peek_slice(&self, length: usize) -> Option<&[u8]>; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/sink/into_enum.rs:30:37 [INFO] [stdout] | [INFO] [stdout] 30 | pub fn new(source: &'a [u8]) -> EnumSink { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 30 | pub fn new(source: &'a [u8]) -> EnumSink<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/sink/into_enum.rs:38:45 [INFO] [stdout] | [INFO] [stdout] 38 | pub fn new_bailing(source: &'a [u8]) -> EnumSink { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 38 | pub fn new_bailing(source: &'a [u8]) -> EnumSink<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Sink` [INFO] [stdout] --> tests/lib.rs:6:37 [INFO] [stdout] | [INFO] [stdout] 6 | use iterative_json_parser::{Source, Sink}; [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constants have by default a `'static` lifetime [INFO] [stdout] --> tests/lib.rs:320:43 [INFO] [stdout] | [INFO] [stdout] 320 | const JSON_TEST_SUITE_ACCEPTABLE_FAILS: [&'static str; 25] = [ [INFO] [stdout] | -^^^^^^^---- help: consider removing `'static`: `&str` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes [INFO] [stdout] = note: `#[warn(clippy::redundant_static_lifetimes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> tests/lib.rs:37:9 [INFO] [stdout] | [INFO] [stdout] 37 | let mut ss = SourceSink { [INFO] [stdout] | ----^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> tests/lib.rs:46:9 [INFO] [stdout] | [INFO] [stdout] 46 | let mut bailing_ss = SourceSink { [INFO] [stdout] | ----^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `result` [INFO] [stdout] --> tests/lib.rs:410:25 [INFO] [stdout] | [INFO] [stdout] 410 | let result = parse_to_enum(&mut buf); [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_result` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> tests/lib.rs:53:5 [INFO] [stdout] | [INFO] [stdout] 53 | return result; [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] 53 - return result; [INFO] [stdout] 53 + result [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> tests/lib.rs:64:9 [INFO] [stdout] | [INFO] [stdout] 64 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] = note: `#[warn(clippy::println_empty_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the function `parse_to_enum_print` doesn't need a mutable reference [INFO] [stdout] --> tests/lib.rs:382:54 [INFO] [stdout] | [INFO] [stdout] 382 | let result = parse_to_enum_print(&mut buf, &test_name, true); [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_mut_passed [INFO] [stdout] = note: `#[warn(clippy::unnecessary_mut_passed)]` on by default [INFO] [stdout] help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] 382 - let result = parse_to_enum_print(&mut buf, &test_name, true); [INFO] [stdout] 382 + let result = parse_to_enum_print(&buf, &test_name, true); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the function `parse_to_enum_print` doesn't need a mutable reference [INFO] [stdout] --> tests/lib.rs:396:54 [INFO] [stdout] | [INFO] [stdout] 396 | let result = parse_to_enum_print(&mut buf, &test_name, false); [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_mut_passed [INFO] [stdout] help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] 396 - let result = parse_to_enum_print(&mut buf, &test_name, false); [INFO] [stdout] 396 + let result = parse_to_enum_print(&buf, &test_name, false); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let` [INFO] [stdout] --> tests/lib.rs:397:21 [INFO] [stdout] | [INFO] [stdout] 397 | / match result { [INFO] [stdout] 398 | | Ok(res) => { [INFO] [stdout] 399 | | if !can_fail { [INFO] [stdout] 400 | | success = false; [INFO] [stdout] ... | [INFO] [stdout] 406 | | Err(_) => (), [INFO] [stdout] 407 | | } [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stdout] = note: `#[warn(clippy::single_match)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 397 ~ if let Ok(res) = result { [INFO] [stdout] 398 + if !can_fail { [INFO] [stdout] 399 + success = false; [INFO] [stdout] 400 + } else { [INFO] [stdout] 401 + println!("ACCEPTABLE"); [INFO] [stdout] 402 + } [INFO] [stdout] 403 + println!("Unexpected ok: {:?} ({:?})", res, can_fail); [INFO] [stdout] 404 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the function `parse_to_enum` doesn't need a mutable reference [INFO] [stdout] --> tests/lib.rs:410:48 [INFO] [stdout] | [INFO] [stdout] 410 | let result = parse_to_enum(&mut buf); [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_mut_passed [INFO] [stdout] help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] 410 - let result = parse_to_enum(&mut buf); [INFO] [stdout] 410 + let result = parse_to_enum(&buf); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.63s [INFO] running `Command { std: "docker" "inspect" "35dff47ad38a328a82202c429bc46b1d770ba098fd5113708b2d485972ad83fa", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "35dff47ad38a328a82202c429bc46b1d770ba098fd5113708b2d485972ad83fa", kill_on_drop: false }` [INFO] [stdout] 35dff47ad38a328a82202c429bc46b1d770ba098fd5113708b2d485972ad83fa