[INFO] cloning repository https://github.com/herisetiawan00/dartrs [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/herisetiawan00/dartrs" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fherisetiawan00%2Fdartrs", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fherisetiawan00%2Fdartrs'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 43e9aadb6f3528160492510f6d497a34cca3d33d [INFO] linting herisetiawan00/dartrs against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fherisetiawan00%2Fdartrs" "/workspace/builds/worker-0-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/herisetiawan00/dartrs [INFO] finished tweaking git repo https://github.com/herisetiawan00/dartrs [INFO] tweaked toml for git repo https://github.com/herisetiawan00/dartrs written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/herisetiawan00/dartrs 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/herisetiawan00/dartrs 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] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded tree-sitter-language v0.1.5 [INFO] [stderr] Downloaded str_indices v0.4.4 [INFO] [stderr] Downloaded ropey v1.6.1 [INFO] [stderr] Downloaded jiff-static v0.2.14 [INFO] [stderr] Downloaded tree-sitter v0.25.6 [INFO] [stderr] Downloaded tree-sitter-dart v0.0.4 [INFO] [stderr] Downloaded syn v2.0.102 [INFO] [stderr] Downloaded jiff v0.2.14 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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] 3833feba457c58511451c81f3a041472214b35200f93fde3fd12d7b59dd26f04 [INFO] running `Command { std: "docker" "start" "-a" "3833feba457c58511451c81f3a041472214b35200f93fde3fd12d7b59dd26f04", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "3833feba457c58511451c81f3a041472214b35200f93fde3fd12d7b59dd26f04", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "3833feba457c58511451c81f3a041472214b35200f93fde3fd12d7b59dd26f04", kill_on_drop: false }` [INFO] [stdout] 3833feba457c58511451c81f3a041472214b35200f93fde3fd12d7b59dd26f04 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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] aa6a7b8564db5487784545cfaf45a2a6712ff07d745cc04cc4dea3f640f39ef9 [INFO] running `Command { std: "docker" "start" "-a" "aa6a7b8564db5487784545cfaf45a2a6712ff07d745cc04cc4dea3f640f39ef9", kill_on_drop: false }` [INFO] [stderr] Checking memchr v2.7.5 [INFO] [stderr] Checking smallvec v1.15.1 [INFO] [stderr] Compiling libc v0.2.172 [INFO] [stderr] Compiling serde v1.0.219 [INFO] [stderr] Compiling lock_api v0.4.13 [INFO] [stderr] Compiling syn v2.0.102 [INFO] [stderr] Compiling serde_json v1.0.140 [INFO] [stderr] Compiling hashbrown v0.15.4 [INFO] [stderr] Compiling slab v0.4.9 [INFO] [stderr] Compiling itoa v1.0.15 [INFO] [stderr] Checking regex-syntax v0.8.5 [INFO] [stderr] Compiling ryu v1.0.20 [INFO] [stderr] Checking aho-corasick v1.1.3 [INFO] [stderr] Compiling indexmap v2.9.0 [INFO] [stderr] Checking futures-channel v0.3.31 [INFO] [stderr] Checking percent-encoding v2.3.1 [INFO] [stderr] Checking parking_lot_core v0.9.11 [INFO] [stderr] Checking form_urlencoded v1.2.1 [INFO] [stderr] Checking parking_lot v0.12.4 [INFO] [stderr] Checking mio v1.0.4 [INFO] [stderr] Checking socket2 v0.5.10 [INFO] [stderr] Checking signal-hook-registry v1.4.5 [INFO] [stderr] Compiling tree-sitter-dart v0.0.4 [INFO] [stderr] Checking log v0.4.27 [INFO] [stderr] Compiling anyhow v1.0.98 [INFO] [stderr] Checking is_terminal_polyfill v1.70.1 [INFO] [stderr] Checking streaming-iterator v0.1.9 [INFO] [stderr] Checking tree-sitter-language v0.1.5 [INFO] [stderr] Checking hashbrown v0.14.5 [INFO] [stderr] Checking anstyle-query v1.1.3 [INFO] [stderr] Checking anstyle v1.0.11 [INFO] [stderr] Checking jiff v0.2.14 [INFO] [stderr] Checking str_indices v0.4.4 [INFO] [stderr] Checking anstream v0.6.19 [INFO] [stderr] Checking regex-automata v0.4.9 [INFO] [stderr] Checking ropey v1.6.1 [INFO] [stderr] Checking dashmap v5.5.3 [INFO] [stderr] Checking regex v1.11.1 [INFO] [stderr] Checking env_filter v0.1.3 [INFO] [stderr] Compiling synstructure v0.13.2 [INFO] [stderr] Compiling tree-sitter v0.25.6 [INFO] [stderr] Compiling zerofrom-derive v0.1.6 [INFO] [stderr] Compiling yoke-derive v0.8.0 [INFO] [stderr] Compiling zerovec-derive v0.11.1 [INFO] [stderr] Compiling displaydoc v0.2.5 [INFO] [stderr] Compiling serde_derive v1.0.219 [INFO] [stderr] Compiling futures-macro v0.3.31 [INFO] [stderr] Compiling tokio-macros v2.5.0 [INFO] [stderr] Compiling pin-project-internal v1.1.10 [INFO] [stderr] Checking tokio v1.45.1 [INFO] [stderr] Checking futures-util v0.3.31 [INFO] [stderr] Compiling serde_repr v0.1.20 [INFO] [stderr] Compiling tracing-attributes v0.1.29 [INFO] [stderr] Checking zerofrom v0.1.6 [INFO] [stderr] Checking yoke v0.8.0 [INFO] [stderr] Compiling async-trait v0.1.88 [INFO] [stderr] Checking zerovec v0.11.2 [INFO] [stderr] Checking zerotrie v0.2.2 [INFO] [stderr] Checking pin-project v1.1.10 [INFO] [stderr] Compiling tower-lsp-macros v0.9.0 [INFO] [stderr] Compiling auto_impl v1.3.0 [INFO] [stderr] Checking tracing v0.1.41 [INFO] [stderr] Checking env_logger v0.11.8 [INFO] [stderr] Checking tinystr v0.8.1 [INFO] [stderr] Checking potential_utf v0.1.2 [INFO] [stderr] Checking icu_collections v2.0.0 [INFO] [stderr] Checking icu_locale_core v2.0.0 [INFO] [stderr] Checking icu_provider v2.0.0 [INFO] [stderr] Checking tower v0.4.13 [INFO] [stderr] Checking futures v0.3.31 [INFO] [stderr] Checking icu_normalizer v2.0.0 [INFO] [stderr] Checking icu_properties v2.0.1 [INFO] [stderr] Checking idna_adapter v1.2.1 [INFO] [stderr] Checking idna v1.0.3 [INFO] [stderr] Checking tokio-util v0.7.15 [INFO] [stderr] Checking url v2.5.4 [INFO] [stderr] Checking lsp-types v0.94.1 [INFO] [stderr] Checking tower-lsp v0.20.0 [INFO] [stderr] Checking dartrs v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused imports: `find_definition`, `find_node_at`, `node_to_lsp_location`, and `position_to_offset` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:1:14 [INFO] [stdout] | [INFO] [stdout] 1 | use helper::{find_definition, find_node_at, node_to_lsp_location, position_to_offset}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `parser::parse_code` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:7:13 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::{parser::parse_code, server::LspContext}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `find_definition`, `find_node_at`, `node_to_lsp_location`, and `position_to_offset` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:1:14 [INFO] [stdout] | [INFO] [stdout] 1 | use helper::{find_definition, find_node_at, node_to_lsp_location, position_to_offset}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `parser::parse_code` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:7:13 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::{parser::parse_code, server::LspContext}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `context` [INFO] [stdout] --> src/handlers/completion.rs:5:21 [INFO] [stdout] | [INFO] [stdout] 5 | pub async fn action(context: &LspContext, params: CompletionParams) -> Result> { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_context` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `params` [INFO] [stdout] --> src/handlers/completion.rs:5:43 [INFO] [stdout] | [INFO] [stdout] 5 | pub async fn action(context: &LspContext, params: CompletionParams) -> Result> { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_params` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `context` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | context: &LspContext, [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_context` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `params` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | params: GotoDefinitionParams, [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_params` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `position_to_offset` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn position_to_offset(source: &str, position: Position) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_node_at` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_definition` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:32:8 [INFO] [stdout] | [INFO] [stdout] 32 | pub fn find_definition<'tree>(tree: &'tree Tree, source: &str, name: &str) -> Option> { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `node_to_lsp_location` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:52:8 [INFO] [stdout] | [INFO] [stdout] 52 | pub fn node_to_lsp_location(uri: Url, source: &str, node: Node) -> Location { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `context` [INFO] [stdout] --> src/handlers/completion.rs:5:21 [INFO] [stdout] | [INFO] [stdout] 5 | pub async fn action(context: &LspContext, params: CompletionParams) -> Result> { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_context` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `params` [INFO] [stdout] --> src/handlers/completion.rs:5:43 [INFO] [stdout] | [INFO] [stdout] 5 | pub async fn action(context: &LspContext, params: CompletionParams) -> Result> { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_params` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: parameter is only used in recursion [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:77:39 [INFO] [stdout] | [INFO] [stdout] 77 | fn get_identifier<'a>(node: Node<'a>, source: &str) -> Option> { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_source` [INFO] [stdout] | [INFO] [stdout] note: parameter used here [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:83:57 [INFO] [stdout] | [INFO] [stdout] 83 | if let Some(identifier) = get_identifier(child, source) { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion [INFO] [stdout] = note: `#[warn(clippy::only_used_in_recursion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:128:16 [INFO] [stdout] | [INFO] [stdout] 128 | } else if is_class_property_node(&child) { [INFO] [stdout] | ________________^ [INFO] [stdout] 129 | | if let Some(found) = find_declaration_on_scope(name, child, source) { [INFO] [stdout] 130 | | return Some(found); [INFO] [stdout] 131 | | } [INFO] [stdout] 132 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 128 ~ } else if is_class_property_node(&child) [INFO] [stdout] 129 ~ && let Some(found) = find_declaration_on_scope(name, child, source) { [INFO] [stdout] 130 | return Some(found); [INFO] [stdout] 131 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&String` instead of `&str` involves a new object where a slice will do [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:139:13 [INFO] [stdout] | [INFO] [stdout] 139 | source: &'a String, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 139 - source: &'a String, [INFO] [stdout] 139 + source: &'a str, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `context` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | context: &LspContext, [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_context` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `params` [INFO] [stdout] --> src/handlers/goto_definition/mod.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | params: GotoDefinitionParams, [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_params` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:36:9 [INFO] [stdout] | [INFO] [stdout] 36 | / if node.kind() == "class_declaration" || node.kind() == "function_declaration" { [INFO] [stdout] 37 | | if let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | | return Some(node); [INFO] [stdout] ... | [INFO] [stdout] 42 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 36 ~ if (node.kind() == "class_declaration" || node.kind() == "function_declaration") { [INFO] [stdout] 37 ~ && let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | return Some(node); [INFO] [stdout] 40 | } [INFO] [stdout] 41 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:37:13 [INFO] [stdout] | [INFO] [stdout] 37 | / if let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | | return Some(node); [INFO] [stdout] 40 | | } [INFO] [stdout] 41 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 37 ~ if let Some(id) = node.child_by_field_name("name") [INFO] [stdout] 38 ~ && id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | return Some(node); [INFO] [stdout] 40 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/handlers/hover/mod.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | if !(uri.path() == ".dart") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(uri.path() != ".dart")` [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: redundant pattern matching, consider using `is_none()` [INFO] [stdout] --> src/handlers/hover/mod.rs:20:12 [INFO] [stdout] | [INFO] [stdout] 20 | if let None = initialize_params { [INFO] [stdout] | -------^^^^-------------------- help: try: `if initialize_params.is_none()` [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: useless use of `format!` [INFO] [stdout] --> src/server.rs:124:45 [INFO] [stdout] | [INFO] [stdout] 124 | .log_message(MessageType::INFO, format!(">>>> goto declaration")) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `">>>> goto declaration".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:15:27 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option { [INFO] [stdout] | ^^^^^ ^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided 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: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `position_to_offset` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn position_to_offset(source: &str, position: Position) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_node_at` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_definition` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:32:8 [INFO] [stdout] | [INFO] [stdout] 32 | pub fn find_definition<'tree>(tree: &'tree Tree, source: &str, name: &str) -> Option> { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `node_to_lsp_location` is never used [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:52:8 [INFO] [stdout] | [INFO] [stdout] 52 | pub fn node_to_lsp_location(uri: Url, source: &str, node: Node) -> Location { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: parameter is only used in recursion [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:77:39 [INFO] [stdout] | [INFO] [stdout] 77 | fn get_identifier<'a>(node: Node<'a>, source: &str) -> Option> { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_source` [INFO] [stdout] | [INFO] [stdout] note: parameter used here [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:83:57 [INFO] [stdout] | [INFO] [stdout] 83 | if let Some(identifier) = get_identifier(child, source) { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion [INFO] [stdout] = note: `#[warn(clippy::only_used_in_recursion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:128:16 [INFO] [stdout] | [INFO] [stdout] 128 | } else if is_class_property_node(&child) { [INFO] [stdout] | ________________^ [INFO] [stdout] 129 | | if let Some(found) = find_declaration_on_scope(name, child, source) { [INFO] [stdout] 130 | | return Some(found); [INFO] [stdout] 131 | | } [INFO] [stdout] 132 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 128 ~ } else if is_class_property_node(&child) [INFO] [stdout] 129 ~ && let Some(found) = find_declaration_on_scope(name, child, source) { [INFO] [stdout] 130 | return Some(found); [INFO] [stdout] 131 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&String` instead of `&str` involves a new object where a slice will do [INFO] [stdout] --> src/handlers/goto_declaration/helper.rs:139:13 [INFO] [stdout] | [INFO] [stdout] 139 | source: &'a String, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 139 - source: &'a String, [INFO] [stdout] 139 + source: &'a str, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:36:9 [INFO] [stdout] | [INFO] [stdout] 36 | / if node.kind() == "class_declaration" || node.kind() == "function_declaration" { [INFO] [stdout] 37 | | if let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | | return Some(node); [INFO] [stdout] ... | [INFO] [stdout] 42 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 36 ~ if (node.kind() == "class_declaration" || node.kind() == "function_declaration") { [INFO] [stdout] 37 ~ && let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | return Some(node); [INFO] [stdout] 40 | } [INFO] [stdout] 41 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:37:13 [INFO] [stdout] | [INFO] [stdout] 37 | / if let Some(id) = node.child_by_field_name("name") { [INFO] [stdout] 38 | | if id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | | return Some(node); [INFO] [stdout] 40 | | } [INFO] [stdout] 41 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 37 ~ if let Some(id) = node.child_by_field_name("name") [INFO] [stdout] 38 ~ && id.utf8_text(source.as_bytes()).unwrap() == name { [INFO] [stdout] 39 | return Some(node); [INFO] [stdout] 40 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/handlers/hover/mod.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | if !(uri.path() == ".dart") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(uri.path() != ".dart")` [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: redundant pattern matching, consider using `is_none()` [INFO] [stdout] --> src/handlers/hover/mod.rs:20:12 [INFO] [stdout] | [INFO] [stdout] 20 | if let None = initialize_params { [INFO] [stdout] | -------^^^^-------------------- help: try: `if initialize_params.is_none()` [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: useless use of `format!` [INFO] [stdout] --> src/server.rs:124:45 [INFO] [stdout] | [INFO] [stdout] 124 | .log_message(MessageType::INFO, format!(">>>> goto declaration")) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `">>>> goto declaration".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/handlers/goto_definition/helper.rs:15:27 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option { [INFO] [stdout] | ^^^^^ ^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided 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: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 15 | pub fn find_node_at(tree: &Tree, offset: usize) -> Option> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1m 09s [INFO] running `Command { std: "docker" "inspect" "aa6a7b8564db5487784545cfaf45a2a6712ff07d745cc04cc4dea3f640f39ef9", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "aa6a7b8564db5487784545cfaf45a2a6712ff07d745cc04cc4dea3f640f39ef9", kill_on_drop: false }` [INFO] [stdout] aa6a7b8564db5487784545cfaf45a2a6712ff07d745cc04cc4dea3f640f39ef9